The jit.phys.picker object responds to mouse clicks and drags in the destination by creating a constraint on jit.phys.body objects intersecting with the mouse. Multi-touch picking is facilitated by the message.
When an intersection occurs, the jit.phys.body name and current mouse-state is sent out the leftmost outlet. If dynamics is enabled, a point-to-point constraint is created on the picked body that persists until the mouse button is released. When dragging a rigid-body with dynamics enabled, holding down the option key will move the object towards and away from the camera. If the option key is held and the mouse is released, the constraint will persist, allowing the mouse to be repositioned on the rigid-body.
The name of the jit.phys.body currently intersecting with the mouse.
Enable/disable dynamic constraint picking intersecting bodies (default = 1).
Enable the picker contraint and ray-testing in the physics simulation (default = 1).
Set the name of this object's collision filter-class (default = default). Other objects most specify the filterclass name in their filters list to enable collisions with this object. Maximum allowed unique names is 10.
filters [10 symbols]
Specify a list of filterclass names to enable collisions with (default = all). Possible values include all and default . Additional values include any user-specified filterclass names (maximum allowed = 10).
Enable/disable mouse hovering allowing for picking without the mouse button down (default = 0).
local_position [3 floats]
The local-space constraint position on the picked body (default = 0 0 0).
Enable/disable the output of local and world position values when an object is selected(default = 0). When enabled the local position on the clicked object, and the world-space position of the constraint are output following the object name and mouse-state.
Determines how the constraint is applied to the intersecting body (default = surface).
'center' ( The constraint is applied to the bodies center of mass )
'surface' ( The constraint is applied to the intersecting surface point )
position [3 floats]
The current constraint picking position (default = 0 0 0).
Set the constraint strength (default = 0.2). Determines what proportion of the joint error will be fixed each simulation step. Values between 0.1 and 0.8 are recommended.
Set the constraint stretch (default = 0.0). Setting to a positive value allows forces acting on rigid bodies to violate the constraint by an amount proportional to the stretch value.
UI priority value (default = -800). When multiple UI objects are listening to the same window, ui_priority determines the order objects receive input. Lower values test first.
The name of a jit.phys.world context this constraint picker is bound to.
Common Box Attributes
Sets the text that will be displayed in the Clue window when the user moves the mouse over the object.
background [int] (default: 0)
Adds or removes the object from the patcher's background layer.adds the object to the background layer, removes it. Objects in the background layer are shown behind all objects in the default foreground layer.
color [4 floats]
Sets the color for the object box outline.
Sets the type style used by the object. The options are:
bold italic Possible values:
0 = 'regular'
1 = 'bold'
2 = 'italic'
3 = 'bold italic'
Sets the object's font.
Sets the object's font size (in points).
hidden [int] (default: 0)
Toggles whether an object is hidden when the patcher is locked.
Sets the text that will be displayed in as a pop-up hint when the user moves the mouse over the object in a locked patcher.
ignoreclick [int] (default: 0)
Toggles whether an object ignores mouse clicks in a locked patcher.
JS Painter File
patching_rect [4 floats] (default: 0. 0. 100. 0.)
Sets the position and size of the object in the patcher window.
position [2 floats]
Sets the object's x and y position in both patching and presentation modes (if the object belongs to its patcher's presentation), leaving its size unchanged.
presentation [int] (default: 0)
Sets whether an object belongs to the patcher's presentation.
presentation_rect [4 floats] (default: 0. 0. 0. 0.)
Sets the x and y position and width and height of the object in the patcher's presentation, leaving its patching position unchanged.
rect [4 floats]
Sets the x and y position and width and height of the object in both patching and presentation modes (if the object belongs to its patcher's presentation).
size [2 floats]
Sets the object's width and height in both patching and presentation modes (if the object belongs to its patcher's presentation), leaving its position unchanged.
textcolor [4 floats]
Sets the color for the object's text in RGBA format.
Sets the justification for the object's text.
0 = 'left'
1 = 'center'
2 = 'right'
|Working with OpenGL||Working with OpenGL|
|jit.phys.world||Collision detection and rigid body dynamics|
|jit.phys.body||A rigid body and collision shape|
|jit.gl.picker||Mouse picking in an opengl context|