OpenXRCompositionLayerCylinder
Cylindrical layer; account for the AspectRatio hit-test limitation.
Displays a viewport on the inside of a cylindrical arc. Radius and CentralAngle define arc width; AspectRatio defines height. API angles are radians. Use positive dimensions and orthonormal transforms; inherited Scale/shear is not a panel-size control.
Native composition needs the cylinder extension; Entity existence and stored parameters establish no submission or pixels. See the layer guide for LayerViewport, alpha, ordering and ownership. FallbackSegments affects the mesh, not native resolution.
Known defect: fallback height is Radius*CentralAngle/AspectRatio, whereas IntersectsRay multiplies by AspectRatio. Current-SDK execution at AspectRatio=2 reproduced a ray hit above the visible fallback panel. For pointer UI use AspectRatio=1 or Quad until a correct custom hit test exists. Engine limitation not fixed.
Fourteen headless checks across Cylinder/Equirect covered parameters, geometric rays and fallback AABB with XR off. Native submission, physical devices, GUI input, WorldScale!=1 and rendering quality remain unverified.
Declarations checked against C# SDK 1.0.0. Expand a name to see declarations and documentation.
Constructors1
OpenXRCompositionLayerCylinderConstructor
public OpenXRCompositionLayerCylinder();Creates a curved layer with default parameters. Starts no OpenXR and assigns no LayerViewport. Native support depends on its shape extension; without API a fallback may be used after tree attachment. Constructor success establishes no image or tracking.
Properties4
AspectRatioProperty
public float AspectRatio { get; set; }Arc-width-to-height ratio, initially 1. Setter rejects <=0. Fallback height is RadiusCentralAngle/AspectRatio, but current IntersectsRay uses RadiusCentralAngle*AspectRatio. At 2, a hit above the visible panel was reproduced. For pointer UI use AspectRatio=1 or Quad until a correct custom hit test exists; scaling does not fix the formula.
CentralAngleProperty
public float CentralAngle { get; set; }Horizontal arc angle in radians, initially Pi/2. Setter rejects <=0; degree-like inspector display does not change C# units. Arc width is Radius*CentralAngle. Setter does not establish all real OpenXR runtime constraints. Match texture aspect and geometry; do not supply 90 instead of Pi/2.
FallbackSegmentsProperty
public uint FallbackSegments { get; set; }Fallback-mesh subdivision count, initially 10. Unsigned; zero is rejected and setter marks geometry dirty. Changes neither native compositor resolution nor geometric ray tests. Equirect subdivides in two directions, increasing memory growth. A very large value is not a quality preset.
RadiusProperty
public float Radius { get; set; }Surface radius, initially 1. Setter rejects <=0, stores it, updates the native shape when an extension exists and marks fallback geometry dirty. Use finite positive values, not Entity Scale. Does not change viewport pixel Size; other WorldScale values were not tested.
Methods8
GetAspectRatiofloat
public float GetAspectRatio();Reads the stored value. Arc-width-to-height ratio, initially 1. Setter rejects <=0. Fallback height is RadiusCentralAngle/AspectRatio, but current IntersectsRay uses RadiusCentralAngle*AspectRatio. At 2, a hit above the visible panel was reproduced. For pointer UI use AspectRatio=1 or Quad until a correct custom hit test exists; scaling does not fix the formula.
floatArc-width-to-height ratio, initially 1. Setter rejects <=0. Fallback height is RadiusCentralAngle/AspectRatio, but current IntersectsRay uses RadiusCentralAngle*AspectRatio. At 2, a hit above the visible panel was reproduced. For pointer UI use AspectRatio=1 or Quad until a correct custom hit test exists; scaling does not fix the formula.
GetCentralAnglefloat
public float GetCentralAngle();Reads the stored value. Horizontal arc angle in radians, initially Pi/2. Setter rejects <=0; degree-like inspector display does not change C# units. Arc width is Radius*CentralAngle. Setter does not establish all real OpenXR runtime constraints. Match texture aspect and geometry; do not supply 90 instead of Pi/2.
floatHorizontal arc angle in radians, initially Pi/2. Setter rejects <=0; degree-like inspector display does not change C# units. Arc width is Radius*CentralAngle. Setter does not establish all real OpenXR runtime constraints. Match texture aspect and geometry; do not supply 90 instead of Pi/2.
GetFallbackSegmentsuint
public uint GetFallbackSegments();Reads the stored value. Fallback-mesh subdivision count, initially 10. Unsigned; zero is rejected and setter marks geometry dirty. Changes neither native compositor resolution nor geometric ray tests. Equirect subdivides in two directions, increasing memory growth. A very large value is not a quality preset.
uintFallback-mesh subdivision count, initially 10. Unsigned; zero is rejected and setter marks geometry dirty. Changes neither native compositor resolution nor geometric ray tests. Equirect subdivides in two directions, increasing memory growth. A very large value is not a quality preset.
GetRadiusfloat
public float GetRadius();Reads the stored value. Surface radius, initially 1. Setter rejects <=0, stores it, updates the native shape when an extension exists and marks fallback geometry dirty. Use finite positive values, not Entity Scale. Does not change viewport pixel Size; other WorldScale values were not tested.
floatSurface radius, initially 1. Setter rejects <=0, stores it, updates the native shape when an extension exists and marks fallback geometry dirty. Use finite positive values, not Entity Scale. Does not change viewport pixel Size; other WorldScale values were not tested.
SetAspectRatiovoid
public void SetAspectRatio(float aspectRatio);Configures the surface parameter. Arc-width-to-height ratio, initially 1. Setter rejects <=0. Fallback height is RadiusCentralAngle/AspectRatio, but current IntersectsRay uses RadiusCentralAngle*AspectRatio. At 2, a hit above the visible panel was reproduced. For pointer UI use AspectRatio=1 or Quad until a correct custom hit test exists; scaling does not fix the formula.
| Name | Type | Default |
|---|---|---|
aspectRatio | float | — |
aspectRatioArc-width-to-height ratio, initially 1. Setter rejects <=0. Fallback height is RadiusCentralAngle/AspectRatio, but current IntersectsRay uses RadiusCentralAngle*AspectRatio. At 2, a hit above the visible panel was reproduced. For pointer UI use AspectRatio=1 or Quad until a correct custom hit test exists; scaling does not fix the formula.
SetCentralAnglevoid
public void SetCentralAngle(float angle);Configures the surface parameter. Horizontal arc angle in radians, initially Pi/2. Setter rejects <=0; degree-like inspector display does not change C# units. Arc width is Radius*CentralAngle. Setter does not establish all real OpenXR runtime constraints. Match texture aspect and geometry; do not supply 90 instead of Pi/2.
| Name | Type | Default |
|---|---|---|
angle | float | — |
angleHorizontal arc angle in radians, initially Pi/2. Setter rejects <=0; degree-like inspector display does not change C# units. Arc width is Radius*CentralAngle. Setter does not establish all real OpenXR runtime constraints. Match texture aspect and geometry; do not supply 90 instead of Pi/2.
SetFallbackSegmentsvoid
public void SetFallbackSegments(uint segments);Configures the surface parameter. Fallback-mesh subdivision count, initially 10. Unsigned; zero is rejected and setter marks geometry dirty. Changes neither native compositor resolution nor geometric ray tests. Equirect subdivides in two directions, increasing memory growth. A very large value is not a quality preset.
| Name | Type | Default |
|---|---|---|
segments | uint | — |
segmentsFallback-mesh subdivision count, initially 10. Unsigned; zero is rejected and setter marks geometry dirty. Changes neither native compositor resolution nor geometric ray tests. Equirect subdivides in two directions, increasing memory growth. A very large value is not a quality preset.
SetRadiusvoid
public void SetRadius(float radius);Configures the surface parameter. Surface radius, initially 1. Setter rejects <=0, stores it, updates the native shape when an extension exists and marks fallback geometry dirty. Use finite positive values, not Entity Scale. Does not change viewport pixel Size; other WorldScale values were not tested.
| Name | Type | Default |
|---|---|---|
radius | float | — |
radiusSurface radius, initially 1. Setter rejects <=0, stores it, updates the native shape when an extension exists and marks fallback geometry dirty. Use finite positive values, not Entity Scale. Does not change viewport pixel Size; other WorldScale values were not tested.