This is a child page. You can use Parent in the quick nav bar at the top or the bottom of the page to navigate directly back to the parent of this page. Some child pages are more than one level deep, and in that case will require more than one Parent click to reach the outermost document level.

§ - refraction (SceneScript element)

 <refraction EXP

This language element may be used inside a  <trait block.

EXP sets what the index of refraction, or "IOR", of a material is.

EXP represents an IOR that can reasonably vary from about 1.0 on upwards.

IOR stands for "Index Of Refraction" and represents a controlling element for how much a light ray will bend when it transits the interface between the object and the atmosphere, when the atmosphere (or another object contained within this one) has a differing IOR. The gems to the right demonstrate varying degrees of refraction and internal reflectivity to good effect.

If you want to create transparency that does not refract — for instance, when you're using a texture with an alpha channel on a rectangle, and where it's clear, you want it to "disappear" rather than act as a transparent substance — then just ensure that the IOR for the plane is the same as the IOR for the atmosphere and it'll work as you expect. If you have a differing IOR, it'll act like a clear material that refracts, instead.

This setting is related to the  <atmosphere language element, which lets you define an IOR for the atmosphere. The atmosphere, as we mean it here, is the otherwise empty space that you're creating objects in.

Here are some reference IOR values you can use:

Medium IOR
Vacuum 1.0
Air 1.0003
Ice 1.309
Water 1.333
Alchohol (Ethyl) 1.36
Flourite 1.434
Glass 1.46 to 1.66
Turpentine 1.472
Glycerine 1.473
Rock Salt 1.544
Quartz 1.544
Ruby 1.72
Zircon 1.923
Diamond 2.417
Keyboard Navigation
, Previous Page . Next Page t TOC i Index o Operators g Glossary
WinImages F/x, Morph and all associated documentation
Copyright © 1992-2007 Black Belt Systems ALL RIGHTS RESERVED Under the Pan-American Conventions
WinImages F/x Manual Version 7, Revision 6, Level A

Valid HTML 4.01 Loose

This manual was generated with wtfm
wtfm uses aa_macro and SqLite
aa_macro uses python 2.7
Page 209