Skip to content

Prop

Introduction

vtkProp is an abstract superclass for any objects that can exist in a rendered scene (either 2D or 3D). Instances of vtkProp may respond to various render methods (e.g., RenderOpaqueGeometry()). vtkProp also defines the API for picking, LOD manipulation, and common instance variables that control visibility, picking, and dragging.

Methods

addEstimatedRenderTime

ArgumentTypeRequiredDescription
estimatedRenderTimeYes

addTexture

ArgumentTypeRequiredDescription
texturevtkTextureYesThe vtkTexture instance.

extend

Method use to decorate a given object (publicAPI+model) with vtkProp characteristics.

ArgumentTypeRequiredDescription
publicAPIYesobject on which methods will be bounds (public)
modelYesobject on which data structure will be bounds (protected)
initialValuesIPropInitialValuesNo(default: {})

getActors

To be reimplemented by subclasses. For some exporters and other other operations we must be able to collect all the actors or volumes.

getActors2D

Not implemented yet

getAllocatedRenderTime

getCoordinateSystem

Get the coordinate system this prop is defined in.

getDragable

Get the value of the dragable instance variable.

getEstimatedRenderTime

The value is returned in seconds. For simple geometry the accuracy may not be great due to buffering. For ray casting, which is already multi-resolution, the current resolution of the image is factored into the time. We need the viewport for viewing parameters that affect timing. The no-arguments version simply returns the value of the variable with no estimation.

getNestedDragable

Combine dragabe property with optional ancestor props dragable properties. It is used to decide whether the prop can be mouse dragged.

getNestedPickable

Combine pickable property with optional ancestor props pickable properties. It is used to decide whether the prop should be rendered during a selection rendering.

getNestedProps

getNestedVisibility

Combine visibility property with optional ancestor props visibility properties. It is used to decide whether the prop should be rendered.

getParentProp

Return parent prop set by setParentProp

getPickable

Get the pickable instance variable.

getRedrawMTime

Return the mtime of anything that would cause the rendered image to appear differently. Usually this involves checking the mtime of the prop plus anything else it depends on such as properties, textures etc.

getRendertimemultiplier

getSupportsSelection

getTextures

getUseBounds

getVisibility

Get visibility of this vtkProp.

getVolumes

Not implemented yet

hasKey

Not Implemented yet

hasTexture

ArgumentTypeRequiredDescription
texturevtkTextureYesThe vtkTexture instance.

newInstance

Method use to create a new instance of vtkProp

ArgumentTypeRequiredDescription
initialValuesIPropInitialValuesNofor pre-setting some of its content

pick

Not Implemented yet Method fires PickEvent if the prop is picked.

removeAllTextures

removeTexture

ArgumentTypeRequiredDescription
texturevtkTextureYesThe vtkTexture instance.

restoreEstimatedRenderTime

This method is used to restore that old value should the render be aborted.

setAllocatedRenderTime

ArgumentTypeRequiredDescription
allocatedRenderTimeYes

setCoordinateSystem

Set the coordinate system that this prop's data should be in. Once the prop has applied any modifiers such as position, orientation userMatrix the resulting values will be treated as in the specified coordinate system. Not all mappers support all coordinate systems.

ArgumentTypeRequiredDescription
coordinateSystemCoordinateSystemYes

setCoordinateSystemToDisplay

Indicate that this prop's data should be in display coordinates. Once the prop has applied any modifiers such as position, orientation userMatrix the resulting values will be treated as in pixel coordinates. That is pixel coordinate with 0,0 in the lower left of the viewport and a z range of -1 at the near plane and 1 at the far. Not all mappers support all coordinate systems.

setCoordinateSystemToWorld

Indicate that this prop's data should be in world coordinates. Once the prop has applied any modifiers such as position, orientation userMatrix the resulting values will be treated as in world coordinates. Not all mappers support all coordinate systems.

setDragable

Set whether prop is dragable. Even if true, prop may not be dragable if an ancestor prop is not dragable.

ArgumentTypeRequiredDescription
dragableYes

setEstimatedRenderTime

ArgumentTypeRequiredDescription
estimatedRenderTimeYes

setParentProp

Set parent prop used by combineVisibility(), combinePickable(), combineDragable()

ArgumentTypeRequiredDescription
parentPropYes

setPickable

Set whether prop is pickable. Even if true, prop may not be pickable if an ancestor prop is not pickable.

ArgumentTypeRequiredDescription
pickableYes

setRenderTimeMultiplier

This is used for culling and is a number between 0 and 1. It is used to create the allocated render time value.

ArgumentTypeRequiredDescription
renderTimeMultiplierNumberYes

setUseBounds

In case the Visibility flag is true, tell if the bounds of this prop should be taken into account or ignored during the computation of other bounding boxes, like in vtkRenderer::ResetCamera().

ArgumentTypeRequiredDescription
useBoundsYes

setVisibility

Set whether prop is visible. Even if true, prop may not be visible if an ancestor prop is not visible.

ArgumentTypeRequiredDescription
visibilityYes