Render Pick CHOP

From Derivative
Jump to: navigation, search


Summary

The Render Pick CHOP samples a rendering (from a Render TOP or a Render Pass TOP) and returns 3D information from the geometry at that particular pick location. Values sampled can include position, normals, point color, texture coordinates, depth and the object's path. An Info DAT should be used to retrieve the object's path.

The pick location is specified through uv coordinates of the rendering. These uv coordinates can be selected by clicking on a Panel Component or explicitly setting them in the U and V parameters in the Render Pick CHOP.

Along with the geometric data returned, this node has two channels 'picked' and 'trigger' that inform the picked status. 'picked' will be 1 when an object has been found at the search location. 'trigger' will be 1 when both an object has been found, and the 'Picking By' condition has been met. That is, either the 'Panel Value' is 1, or the 'Select' parmeter is 'On.

See also the multi-sample Render Pick DAT.

PythonIcon.pngrenderpickCHOP_Class


Parameters - Render Pick Page

Strategy strategy - - Decides when to update values based on pick interactions.

  • While Select select -
  • Hold First Picked holdfirst - Holds the values first returned when geometry picked.
  • Hold Last Picked holdlast - Holds the values last returned when geometry picked. This differs from the Continuous strategy in that it will hold the last values picked on geometry if the pick starts sampling empty space (no geometry in that part of the scene). Alternatively, using the Continuous strategy the values will be cleared to zero if the pick starts sampling empty space.
  • Always always -

Clear Previous Pick on New Pick clearprev - This parameter is only enabled when the Strategy is set to Hold Last Picked. When this is on, starting a new pick on empty space will clear the values. When off, the last values will be held if the pick starts on empty space.

Response Time responsetime - - Determines when the values are updated.

  • Next Cook (Faster) nextcook - The values are captured on the current frame and updated next frame. Results are from the previous frame, but much faster cook times.
  • This Cook (Slower) thiscook - The values are captured and updated in the current frame.

Pick Radius pickradius - Controls the radius of the search area for the pick. If nothing is found at the pick's center it will keep searching for geometry in the search area defined by the Pick Radius.

Pick Radial Step pickradstep - Used to reduce the searching within the search area. The search area is sampled at locations that correspond to 'spokes' outwards from the center pick point.

Pick Circular Step pickcirstep - Used to reduce the searching within the search area. The search area is sampled at locations that correspond to 'rings' outwards from the center pick point.

Render/RenderPass TOP rendertop - Specifies which render to sample.

Texture Sampling Parameters

Use Pickable Flags usepickableflags - When turned on only geometry whose Pickable Flag is on can be selected by the Render Pick CHOP. The Pickable Flag is found on all Object components.

Include Non-Pickable Objects includenonpickable - Includes the non-pickable objects in the picking algorithm such that non-pickable objects may occlude pickable objects. For example, if there is only one pickable object in the scene with lots of additional non-pickable geometry is present, turning this parameter on will prevent the pickable object from being selected if it is behind a non-pickage object (occluded by the non-pickage object).

Picking by pickingby - - Determines how the pick location is set.

  • Panel panel - Uses the Panel Component scoped in the Panel parameter. The uv position of the mouse on this component's control panel will be the uv position in the render that is sampled. The pick is active when the panel value specified by the Panel Value parameter is 1.
  • Parameters parameters - Uses the U, V, and Pick parameters below for picking.

Panel panel - Specifies which panel component to use when picking by panel.

Panel Value panelvalue - Specifies with panel value to use to trigger the pick when picking by panel.

U picku - Sets the u coordinate when picking by parameters.  

V pickv - Sets the v coordinate when picking by parameters.  

Select select - When picking by parameters, picking is active when this parameter = 1.

Activate Callbacks activatecallbacks - Enables Callback DAT for each pick event.

Callbacks DAT callbacks - Path to a DAT containing callbacks for pick event received.



Parameters - Options Page

Fetch Position position - - Returns the position of the point picked on the geometry. Channels tx, ty, tz.

  • No no - Do not return position values.
  • In SOP Space sopspace - Return position of point picked in SOP transform space.
  • In World Space worldspace - Return position of point picked in world transform space.
  • In Camera Space cameraspace - Return position of point picked in camera transform space.
  • Relative to Object relativetoobj - Return position of point picked relative to object specified in Reference Object parameter.

Fetch Normal normal - - Returns the normals of the point picked on the geometry. Channels nx, ny, nz.

  • No no - Do not return normal values.
  • In SOP Space sopspace - Return normals of point picked in SOP transform space.
  • In World Space worldspace - Return normals of point picked in world transform space.
  • In Camera Space cameraspace - Return normals of point picked in camera transform space.
  • Relative to Object relativetoobj - Return normals of point picked relative to object specified in Reference Object parameter.

Reference Object referenceobj - Object used when fetching position or normals Relative to Object.

Fetch Point Color color - Returns the point color of the point picked on the geometry. Channels cr, cg, cb, ca.

Fetch Texture UV uv - Returns the texture coordinates of the point picked on the geometry. Channels mapu, mapv, mapw.

Fetch Object Path path - Return the path to the object that is picked. This result requires and Info DAT with its Node Path parameter referecning the Render Pick CHOP.

Fetch Depth depth - Returns the depth of the point picked on the geometry. This value a non-linear ratio of the point's position between the near and far planes of the Depth Buffer. Channel is depth.

Fetch Instance ID instanceid - Returns the Instance ID of the object. This will always be 0 if instancing is off. Channel is instance.

Custom Attrib 1 customattrib1 - Specify which custom attributes to return from the object.

Custom Attrib 1 Type customattrib1type - - The type of attribute is selected from this menu.

Custom Attrib 2 customattrib2 - Specify which custom attributes to return from the object.

Custom Attrib 2 Type customattrib2type - - The type of attribute is selected from this menu.

Custom Attrib 3 customattrib3 - Specify which custom attributes to return from the object.

Custom Attrib 3 Type customattrib3type - - The type of attribute is selected from this menu.

Custom Attrib 4 customattrib4 - Specify which custom attributes to return from the object.

Custom Attrib 4 Type customattrib4type - - The type of attribute is selected from this menu.



Parameters - Common Page

Time Slice timeslice - Turning this on forces the channels to be "Time Sliced". A Time Slice is the time between the last cook frame and the current cook frame.

Scope scope - To determine which channels get affected, some CHOPs use a Scope string on the Common page.

Sample Rate Match srselect - - Handle cases where multiple input CHOPs' sample rates are different. When Resampling occurs, the curves are interpolated according to the Interpolation Method Option, or "Linear" if the Interpolate Options are not available.

  • Resample At First Input's Rate first - Use rate of first input to resample others.
  • Resample At Maximum Rate max - Resample to the highest sample rate.
  • Resample At Minimum Rate min - Resample to the lowest sample rate.
  • Error If Rates Differ err - Doesn't accept conflicting sample rates.

Export Method exportmethod - - This will determine how to connect the CHOP channel to the parameter. Refer to the Export article for more information.

  • DAT Table by Index datindex - Uses the docked DAT table and references the channel via the index of the channel in the CHOP.
  • DAT Table by Name datname - Uses the docked DAT table and references the channel via the name of the channel in the CHOP.
  • Channel Name is Path:Parameter autoname - The channel is the full destination of where to export to, such has geo1/transform1:tx.

Export Root autoexportroot - This path points to the root node where all of the paths that exporting by Channel Name is Path:Parameter are relative to.

Export Table exporttable - The DAT used to hold the export information when using the DAT Table Export Methods (See above).



CHOPs
Ableton Link • Analyze • Angle • Attribute • Audio Band EQ • Audio Device In • Audio Device Out • Audio Dynamics • Audio File In • Audio Filter • Audio Movie • Audio Oscillator • Audio Para EQ • Audio Play • Audio Render • Audio Spectrum • Audio Stream In • Audio Stream Out • Beat • BlackTrax • Blend • Clip Blender • Clip • Clock • Composite • Constant • Copy • Count • CPlusPlus • Cross • Cycle • DAT to • Delay • Delete • DMX In • DMX Out • Envelope • EtherDream • Event • Expression • Extend • Fan • Feedback • File In • File Out • Filter • Function • Gesture • Handle • Helios DAC • Hog • Hokuyo • Hold • In • Info • Interpolate • Introduction To CHOPs id• Inverse Curve • Inverse Kin • Join • Joystick • Keyboard In • Keyframe • Kinect • Lag • Leap Motion • Leuze ROD4 • LFO • Limit • Logic • Lookup • LTC In • LTC Out • Math • Merge • MIDI In • MIDI In Map • MIDI Out • Mouse In • Mouse Out • NatNet In • Noise • Null • Object • Oculus Audio • Oculus Rift • OpenVR • OSC In • OSC Out • Out • Override • Panel • Parameter • Pattern • Perform • Pipe In • Pipe Out • PosiStageNet • Pulse • RealSense • Record • Rename • Render Pick • Reorder • Replace • Resample • S Curve • Scan • Script • Select • Sequencer • Serial • Shared Mem In • Shared Mem Out • Shift • Shuffle • Slope • SOP to • Sort • Speed • Splice • Spring • Stretch • Switch • Sync In • Sync Out • Tablet • Time Slice • Timeline • Timer • TOP to • Touch In • Touch Out • Trail • Transform • Trigger • Trim • Warp • Wave • ZED

An Operator Family which operate on Channels (a series of numbers) which are used for animation, audio, mathematics, simulation, logic, UI construction, and many other applications.

The internal states of a panel component are Panel Values, and are accessed with a Panel CHOP, a OP.panel Python expression, or a Panel Execute DAT.

To re-compute the output data of the Operators. An operator cooks when (1) its inputs change, (2) its Parameters change, (3) when the timeline moves forward in some cases, or (4) Scripting commands are run on the node. When the operator is a Gadget, it also cooks when a user interacts with it. When an operator cooks, it usually causes operators connected to its output to re-cook. When TouchDesigner draws the screen, it re-cooks all the necessary operators in all Networks, contributing to a frame's total "cook time".

An Operator Family that creates, composites and modifies images, and reads/writes images and movies to/from files and the network. TOPs run on the graphics card's GPU.

A custom interactive control panel built within TouchDesigner. Panels are created using Panel Components whose look is created entirely with TOPs.

The component types (e.g. Slider, Button, Field, Container) that are used to create custom control panels, also known simply as Panel or Gadget

Some operators have a DAT docked to them that contains some python functions. These functions, called "callbacks", get called when something in the operator changes.

An Operator Family that manipulates text strings: multi-line text or tables. Multi-line text is often a command Script, but can be any multi-line text. Tables are rows and columns of cells, each containing a text string.

The location of an operator within the TouchDesigner environment, for example, /geo1/torus1, a node called torus1 in a component called geo1. The path / is called Root. To refer instead to a filesystem folder, directory, disk file or http: address, see Folder.

An Operator Family that reads, creates and modifies 3D polygons, curves, NURBS surfaces, spheres, meatballs and other 3D surface data.

The component types that are used to render 3D scenes: Geometry Component contain the 3D shapes to render, plus Camera, Light, Ambient Light, Null, Bone, Handle and other component types.

A Link.

Each SOP has a list of Points. Each point has an XYZ 3D position value plus other optional attributes. Each polygon Primitive is defined by a vertex list, which is list of point numbers.

(1) A Geometry Component can render its SOP geometry many times using CHOP samples, (2) an OP that doesn't actually have its own data, but rather just refers to an OP (or has an input) whose data it uses. This includes Null OPs, Select OPs and Switch OPs.

A Time Slice is the time from the last cook frame to the current cook frame. In CHOPs it is the set of short channels that only contain the CHOP channels' samples between the last and the current cook frame.

A parameter in most CHOPs that restricts which channels of that CHOP will be affected. Normally all channels of a CHOP are affected by the operator.

samples-per-second of a CHOP. Each CHOP in your network has a sample rate, whether it is used or not. The overall timeline has a "frame rate", which is the number of animation frames per second, generally your monitor display frequency.

Exporting is the connection of CHOP channels to parameters of operators. The output of each exporting CHOP is one or more channels, active only while the CHOP Viewer is on. The current value of a channel can be exported to a parameter of any operator, overriding that parameter's value. See Parameter.

Parameters in TouchDesigner are an operator's settings (numbers, menus, flags, strings, paths) which the user can alter. Parameters for any operator can be opened by right-clicking on the operator and selecting "Parameters..." A currently selected operator's parameters can be viewed in a Network Editor by pressing the keyboard shortcut 'p'.

TouchDesigner is a hierarchy of components. "root" is the top-most network in the hierarchy. The Path is simply /. A typical path is /project1/moviein1.