Intersection

Inheritance diagram

Inheritance diagram of ORSModel.ors.Intersection, ORSModel.ors.Unmanaged, ORSModel.ors.ORSBaseClass

Classes

Intersection

class ORSModel.ors.Intersection

Bases: Unmanaged

Represents a ray pick result.

See also

View::pick(), Node::pick()

getClassNameStatic() str

getClassNameStatic

Returns:

output (str) –

getClosestVisual(self) ORSModel.ors.Visual

See also

getHighlightedVisual(), ORSModel.ors.Intersection.getFarthestVisual()

Returns:

output (ORSModel.ors.Visual) –

getClosestVisualOfClass(self, pProgId: str) ORSModel.ors.Visual

See also

getHighlightedVisual(), ORSModel.ors.Intersection.getFarthestVisual()

Parameters:

pProgId (str) –

Returns:

output (ORSModel.ors.Visual) –

getColor(self) ORSModel.ors.Color

Returns the color value of the intersection.

Returns:

output (ORSModel.ors.Color) – a color (a Color)

getColorInPhysicalUnits(self) ORSModel.ors.Color

Gets the color value, adjusted to physical units (slope and offset).

Returns:

output (ORSModel.ors.Color) – the color (a Color)

getControlPointIndexHit(self) int
Returns:

output (int) –

getDataUnit(self) str
Returns:

output (str) –

getDistance(self) float

Returns the distance from the ray pick origin to the intersection.

Note

Distances are calculated in pixels.

Returns:

output (float) – a double

getFarthestVisual(self) ORSModel.ors.Visual

See also

getHighlightedVisual(), ORSModel.ors.Intersection.getClosestVisual()

Returns:

output (ORSModel.ors.Visual) –

getFarthestVisualOfClass(self, pProgId: str) ORSModel.ors.Visual

See also

getHighlightedVisual(), ORSModel.ors.Intersection.getClosestVisual()

Parameters:

pProgId (str) –

Returns:

output (ORSModel.ors.Visual) –

getHit(self) bool

Checks if the ray pick intersects something.

Returns:

output (bool) – true if the intersection is valid, false otherwise

getHitCount(self) int
Returns:

output (int) –

getMeshFace(self) int

When picking a mesh, returns the face index of the triangle being picked.

Returns:

output (int) – a face index in the mesh (a int32_t*)

getMeshFaceBary1(self) float

See also

getBary2()

Returns:

output (float) –

getMeshFaceBary2(self) float

See also

getBary2()

Returns:

output (float) –

getMeshVertexIndex0(self) int

When picking a mesh, returns the index 1 of the vertex being picked.

Returns:

output (int) – a vertex index 1 (a int32_t*)

getMeshVertexIndex1(self) int

When picking a mesh, returns the index 1 of the vertex being picked.

Returns:

output (int) – a vertex index 1 (a int32_t*)

getMeshVertexIndex2(self) int

When picking a mesh, returns the index 1 of the vertex being picked.

Returns:

output (int) – a vertex index 1 (a int32_t*)

getNearestMeshVertexIndex(self) int

When picking a mesh, returns the vertex index nearest to the point being picked.

Returns:

output (int) – a vertex index in the mesh (a int32_t*)

getNthDistance(self, nth: int) float
Parameters:

nth (int) –

Returns:

output (float) –

getNthLabel(self, nth: int) int
Parameters:

nth (int) –

Returns:

output (int) –

getNthMeshFace(self, nth: int) int
Parameters:

nth (int) –

Returns:

output (int) –

getNthMeshFaceBary1(self, nth: int) float
Parameters:

nth (int) –

Returns:

output (float) –

getNthMeshFaceBary2(self, nth: int) float
Parameters:

nth (int) –

Returns:

output (float) –

getNthMeshVertexIndex0(self, nth: int) int
Parameters:

nth (int) –

Returns:

output (int) –

getNthMeshVertexIndex1(self, nth: int) int
Parameters:

nth (int) –

Returns:

output (int) –

getNthMeshVertexIndex2(self, nth: int) int
Parameters:

nth (int) –

Returns:

output (int) –

getNthNearestMeshVertexIndex(self, nth: int) int
Parameters:

nth (int) –

Returns:

output (int) –

getNthPositionInLocalCoordinates(self, nth: int) ORSModel.ors.Vector3
Parameters:

nth (int) –

Returns:

output (ORSModel.ors.Vector3) –

getNthPositionInWorldCoordinates(self, nth: int) ORSModel.ors.Vector3
Parameters:

nth (int) –

Returns:

output (ORSModel.ors.Vector3) –

getNthScalarValue(self, nth: int) float
Parameters:

nth (int) –

Returns:

output (float) –

getOffset(self) float

Gets the intersection offset, which is the offset of the channel being picked.

Returns:

output (float) – the offset (a double)

getPickDirection(self) ORSModel.ors.Vector3
Returns:

output (ORSModel.ors.Vector3) –

getPickOrigin(self) ORSModel.ors.Vector3
Returns:

output (ORSModel.ors.Vector3) –

getPixelPositionInView(self) ORSModel.ors.Vector3

Returns the position of the intersection in screen coordinates.

Returns:

output (ORSModel.ors.Vector3) – a point (an Vector3)

getPositionInLocalCoordinates(self) ORSModel.ors.Vector3

Returns the position of the intersection in local coordinates.

Returns:

output (ORSModel.ors.Vector3) – a point (a Vector3)

getPositionInVoxelIndex(self) ORSModel.ors.Vector3

Returns the position of the intersection as X/Y/Z indicies.

Note

The point vector will contain X/Y/Z indicies.

Returns:

output (ORSModel.ors.Vector3) – a point (an Vector3)

getPositionInWorldCoordinates(self) ORSModel.ors.Vector3

Returns the position of the intersection in world coordinates.

Returns:

output (ORSModel.ors.Vector3) – a point (an Vector3)

getScalarValue(self) float

Returns the scalar value of the picked triangle.

Returns:

output (float) – the scalar value (a double)

getSlope(self) float

Gets the intersection slope, which is the slope of the channel being picked.

Returns:

output (float) – the slope (a double)

getStructuredGridAtIndex(self, iIndex: int) ORSModel.ors.StructuredGrid

Note

Since more than one visual can be found by the pick ray, either because visuals are superimposed or because they are found within the pick tolerance, this method returns the Nth visual.

Parameters:

iIndex (int) – the structured grid index (an unsigned short, zero based)

Returns:

output (ORSModel.ors.StructuredGrid) – a structured grid (a StructuredGrid), or NULL if the index given is invalid

getStructuredGridCount(self) int
Returns:

output (int) –

getTimeStep(self) int

Returns the T value of the intersection.

Returns:

output (int) – a uint32_t

getVisualAtIndex(self, iIndex: int) ORSModel.ors.Visual

Note

Since more than one visual can be found by the pick ray, either because visuals are superimposed or because they are found within the pick tolerance, this method returns the Nth visual.

Parameters:

iIndex (int) – the visual index (an unsigned short, zero based)

Returns:

output (ORSModel.ors.Visual) – a visual (a Visual), or NULL if the index given is invalid

getVisualCount(self) int
Returns:

output (int) –

getVoxelIndex(self) int
Returns:

output (int) –

getWindowLeveledNormalizedValue(self) float

Returns the value with window leveling applied, normalized between 0 and 1.

Returns:

output (float) – a double between 0 and 1

getXIndexInCurvedChannel(self) float
Returns:

output (float) –

getYIndexInCurvedChannel(self) float
Returns:

output (float) –

none() Intersection
Returns:

output (Intersection) –

Unmanaged

class ORSModel.ors.Unmanaged

Bases: ORSBaseClass

Abstract class for objects that are not managed by the core library. Unmanaged objects are transient objects.

atomicLoad(sFilename: str) Unmanaged

Creates an object from a file where an object was saved.

Parameters:

sFilename (str) – path of the file to load

Returns:

output (Unmanaged) – an unmanaged object, or none() if the load fails

atomicSave(self, aFilename: str) int

Saves the object to a file.

Parameters:

aFilename (str) – path of the file to save

Returns:

output (int) – 0 if successful, otherwise an error code

createFromPythonRepresentation(aPythonRepresentation: str) ORSModel.ors.Unmanaged

Create aUnmanaged Object from a python representation a static method.

Parameters:

aPythonRepresentation (str) –

Returns:

output (ORSModel.ors.Unmanaged) –

fromPythonRepresentation(self, aPythonRepresentation: str) bool

Create aUnmanaged object from a Python string representation.

Parameters:

aPythonRepresentation (str) – a Python evaluable string representation (a string)

Returns:

output (bool) – true if parsing worked, false otherwise (a bool)

getClassName(self) str

Retrieves the class name of the core object wrapped by this Interface object.

Returns:

output (str) –

getClassNameStatic() str

getClassNameStatic

Returns:

output (str) –

getDataChecksum(self) str
Returns:

output (str) –

getIsInstanceOf(self, pProgId: str) bool

Queries the object to know if it is an instance of a certain class.

Parameters:

pProgId (str) –

Returns:

output (bool) –

getPythonRepresentation(self) str

Gets a Python evaluable string representation.

Returns:

output (str) –

isNone(self) bool

Checks if the receiver is none.

Returns:

output (bool) –

isNotNone(self) bool

Checks if the receiver is not none.

Returns:

output (bool) –

none() Unmanaged
Returns:

output (Unmanaged) –

ORSBaseClass

class ORSModel.ors.ORSBaseClass

An abstract class from which all objects issued from the ORS Core Library inherit.

getPythonTraceBack() List[str]

Set the python traceback for a call from python.

Returns:

output (List[str]) –

isManaged(self) bool
Returns:

output (bool) –

isNone(self) bool
Returns:

output (bool) –

setPythonTraceBack(tb: List[str])

Set the python traceback for a call from python.

Parameters:

tb (List[str]) –