ReferenceDirection
The reference direction vector components.
Example
app = cf.GetApplication() project = app:NewProject() -- Create a layered anisotropic dielectric dielectric1 = project.Media:AddDielectric(cf.Dielectric.GetDefaultProperties()) dielectric2 = project.Media:AddDielectric(cf.Dielectric.GetDefaultProperties()) layeredMedium = project.Media:AddLayeredAnisotropicDielectric({0.001}, {0}, {dielectric1}, {dielectric2}) -- Create a cuboid and set region to free space cuboid = project.Geometry:AddCuboid(cf.Point(0, 0, 0), 1, 1, 1) cuboid.Regions[1].Medium = project.Media:GetFreeSpace() -- Set the face media to the layered dielectric -- Set the medium reference direction vector -- These must be set in one action so a properties table is used properties = cuboid.Faces[1]:GetProperties() properties.Medium = layeredMedium properties.ReferenceDirection.Start = cf.Point(0,0,0) properties.ReferenceDirection.End = cf.Point(1,0,0) cuboid.Faces[1]:SetProperties(properties)
Usage locations (object properties)
The following objects have properties using the ReferenceDirection object:
Property List
- End
- The end coordinates. (Read/Write GlobalCoordinates)
- Start
- The start coordinates. (Read/Write GlobalCoordinates)
Property Details
- End
- The end coordinates.
- Type
- GlobalCoordinates
- Access
- Read/Write
- Start
- The start coordinates.
- Type
- GlobalCoordinates
- Access
- Read/Write