ZOSAPI.Editors.NCE.IObjectDetectorRectangle Interface Reference
Last update: 17.07.2025
Inheritance diagram for ZOSAPI.Editors.NCE.IObjectDetectorRectangle:

Detailed Description
Usage (see Example 17 for a full sample)
C#
//Detector Rectangle
IObjectTypeSettings oType_3 = Object_3.GetObjectTypeSettings(ZOSAPI.Editors.NCE.ObjectType.DetectorRectangle);
Object_3.RefObject = 2;
Object_3.ZPosition = 42;
Object_3.Material = "ABSORB";
Object_3.ChangeType(oType_3);
IObjectDetectorRectangle DetRect3_data = Object_3.ObjectData as IObjectDetectorRectangle;
DetRect3_data.XHalfWidth = 15;
DetRect3_data.YHalfWidth = 15;
DetRect3_data.NumberXPixels = 25;
DetRect3_data.NumberYPixels = 25;
DetRect3_data.DataType = 0;
DetRect3_data.Color = 2;
DetRect3_data.Smoothing = 1;
Definition: InterfacesNCE.cs:3274
This interface is used for selecting any files required by a object, and for changing object types....
Definition: InterfacesNCE.cs:1110
Definition: InterfacesNCE.cs:19
Definition: InterfacesEditors.cs:12
The ZOSAPI namespace contains classes for initially connecting to zemax. See also ZOSAPI_Connection,...
Definition: IAS_FieldCurvatureAndDistortion.cs:5
C++
//Detector Rectangle
IObjectTypeSettingsPtr oType_3 = Object_3->GetObjectTypeSettings(ObjectType_DetectorRectangle);
Object_3->RefObject = 2;
Object_3->ZPosition = 42;
Object_3->Material = "ABSORB";
Object_3->ChangeType(oType_3);
IObjectDetectorRectanglePtr DetRect3_data = Object_3->ObjectData;
DetRect3_data->XHalfWidth = 15;
DetRect3_data->YHalfWidth = 15;
DetRect3_data->NumberXPixels = 25;
DetRect3_data->NumberYPixels = 25;
DetRect3_data->DataType = 0;
DetRect3_data->Color = 2;
DetRect3_data->Smoothing = 1;
Matlab
% Detector Rectangle
Object_3.RefObject = 2;
Object_3.ZPosition = 42;
Object_3.Material = 'ABSORB';
Object_3.ChangeType(oType_3);
DetRect3_data = Object_3.ObjectData;
DetRect3_data.XHalfWidth = 15;
DetRect3_data.YHalfWidth = 15;
DetRect3_data.NumberXPixels = 25;
DetRect3_data.NumberYPixels = 25;
DetRect3_data.DataType = 0;
DetRect3_data.Color = 2;
DetRect3_data.Smoothing = 1;
@ Rectangle
Python
# Detector Rectangle
oType_3 = Object_3.GetObjectTypeSettings(ZOSAPI.Editors.NCE.ObjectType.DetectorRectangle)
Object_3.RefObject = 2
Object_3.ZPosition = 42
Object_3.Material = "ABSORB"
Object_3.ChangeType(oType_3)
DetRect3_data = Object_3.ObjectData
DetRect3_data.XHalfWidth = 15
DetRect3_data.YHalfWidth = 15
DetRect3_data.NumberXPixels = 25
DetRect3_data.NumberYPixels = 25
DetRect3_data.DataType = 0
DetRect3_data.Color = 2
DetRect3_data.Smoothing = 1
Property Documentation
◆ Color
|
getset |
◆ ColorCell
|
get |
◆ DataType
|
getset |
◆ DataTypeCell
|
get |
◆ FrontOnly
|
getset |
◆ FrontOnlyCell
|
get |
◆ Mirroring
|
getset |
◆ MirroringCell
|
get |
◆ NumberXPixels
|
getset |
◆ NumberXPixelsCell
|
get |
◆ NumberYPixels
|
getset |
◆ NumberYPixelsCell
|
get |
◆ PlotScale
|
getset |
◆ PlotScaleCell
|
get |
◆ Polarization
|
getset |
◆ PolarizationCell
|
get |
◆ PsfWaveNumber
|
getset |
◆ PsfWaveNumberCell
|
get |
◆ Scale
|
getset |
◆ ScaleCell
|
get |
◆ Smoothing
|
getset |
◆ SmoothingCell
|
get |
◆ XAngleMax
|
getset |
◆ XAngleMaxCell
|
get |
◆ XAngleMin
|
getset |
◆ XAngleMinCell
|
get |
◆ XHalfWidth
|
getset |
Usage (see Example 06 for a full sample)
C#
// modify object's cell values in the NCE
((IObjectSources)o1.ObjectData).NumberOfAnalysisRays = (int)1e6;
((IObjectSources)o1.ObjectData).NumberOfLayoutRays = 10;
((IObjectSourcePoint)o1.ObjectData).ConeAngle = 2.5;
o2.ZPosition = 1;
((IObjectDetectorRectangle)o2.ObjectData).XHalfWidth = 0.1;
((IObjectDetectorRectangle)o2.ObjectData).YHalfWidth = 0.1;
((IObjectDetectorRectangle)o2.ObjectData).NumberXPixels = 100;
((IObjectDetectorRectangle)o2.ObjectData).NumberYPixels = 100;
Definition: InterfacesNCE.cs:4937
Definition: InterfacesNCE.cs:4712
C++
// modify object's cell values in the NCE
((IObjectSourcesPtr)o1->ObjectData)->NumberOfAnalysisRays = (int)1e6;
((IObjectSourcesPtr)o1->ObjectData)->NumberOfLayoutRays = 10;
((IObjectSourcePointPtr)o1->ObjectData)->ConeAngle = 2.5;
o2->ZPosition = 1;
((IObjectDetectorRectanglePtr)o2->ObjectData)->XHalfWidth = 0.1;
((IObjectDetectorRectanglePtr)o2->ObjectData)->YHalfWidth = 0.1;
((IObjectDetectorRectanglePtr)o2->ObjectData)->NumberXPixels = 100;
((IObjectDetectorRectanglePtr)o2->ObjectData)->NumberYPixels = 100;
Matlab
% modify object's cell values in the NCE
o1.ObjectData.NumberOfAnalysisRays = 1e6;
o1.ObjectData.NumberOfLayoutRays = 10;
o1.ObjectData.ConeAngle = 2.5;
o2.ZPosition = 1;
o2.ObjectData.XHalfWidth = 0.1;
o2.ObjectData.YHalfWidth = 0.1;
o2.ObjectData.NumberXPixels = 100;
o2.ObjectData.NumberYPixels = 100;
Python
# modify object's cell values in the NCE
o1.ObjectData.NumberOfAnalysisRays = 1e6
o1.ObjectData.NumberOfLayoutRays = 10
o1.ObjectData.ConeAngle = 2.5
o2.ZPosition = 1
o2.ObjectData.XHalfWidth = 0.1
o2.ObjectData.YHalfWidth = 0.1
o2.ObjectData.NumberXPixels = 100
o2.ObjectData.NumberYPixels = 100
◆ XHalfWidthCell
|
get |
◆ YAngleMax
|
getset |
◆ YAngleMaxCell
|
get |
◆ YAngleMin
|
getset |
◆ YAngleMinCell
|
get |
◆ YHalfWidth
|
getset |
◆ YHalfWidthCell
|
get |
Properties inherited from