DAT to SOP

From Derivative
Jump to: navigation, search

Summary
[edit]

The DAT to SOP can be used to create geometry from DAT tables, or if a SOP input is specified, to modify attributes on existing geometry. See also the Add SOP.

Without a SOP input, the output is created entirely from the DAT, one SOP point per row of the DAT, except for an optional top row with column headings. The common columns headings include the point number index, point position P(0) P(1) P(2), point weight Pw, the color and alpha Cd(0) Cd(1) Cd(2) Cd(3), texture coordinates uv(0) uv(1) uv(2), and point normal N(0) N(1) N(2). If no index column is specified, row number is used as the point number. If there is no heading for the Point DAT, the list of attributes is assumed to be in order P(0) P(1) P(2) Pw Cd(0) Cd(1) Cd(2) Cd(3) N(0) N(1) N(2) uv(0) uv(1) uv(2) for the first 14 columns. If an input is used, attributes are read in and replace the ones in the existing geometry. The Merge parameter will be enabled when an input is connected. Depending on the Merge menu setting, either the Points DAT or Primitive DAT parameter used for the merge data. If an input is used, the Points or Primitives DAT must have a column named index. This column is used to match the point or primitive to the incoming geometry by point or primitive number.

Attributes in the columns headings should have column name attrib if it is a single value attribute, or have multiple columns named attrib(0), attrib(1), attrib(2) etc if it is a multiple-value attribute.

Data can also be converted into a form that can be rendered as particles.

Example File : File:SOPtoDATtoSOP.tox

PythonIcon.pngdattoSOP_Class


Parameters - Page

Points DAT pointsdat - DAT with point data. The optional index indicates the point number, if none is specified, row number will be used. Attributes can be specified in attribute_name(attribute_index). If there are no named column headings for the Point DAT, the index column should be removed and the list of attributes is assumed to be in order P(0) P(1) P(2) Pw Cd(0) Cd(1) Cd(2) Cd(3) N(0) N(1) N(2) uv(0) uv(1) uv(2) for the first 14 columns. Sample point data:

   index	P(0)	P(1)	P(2)	Pw	N(0)	N(1)	N(2)									
   0		-0.5	-0.5	-0.5	1	0	0	-1								
   1		-0.5	0.5	-0.5	1	0	0	-1								
   2		0.5	0.5	-0.5	1	0	0	-1								
   3		0.5	-0.5	-0.5	1	0	0	-1								
   ...																

The common columns attributes include point position P(0) P(1) P(2), point weight Pw, the color and alpha Cd(0) Cd(1) Cd(2) Cd(3), texture coordinates uv(0) uv(1) uv(2), and point normal N(0) N(1) N(2). See Point Attributes for a list of attributes.

Vertices DAT verticesdat - DAT with vertex data. index indicates the primitive number and vindex the vertex number in that primitive. Attributes are specified in the same manner as for points. ample vertex data:

   index	vindex	uv(0)	uv(1)	uv(2)												
   0		0	0	0	0											
   0		1	0	1	0											
   0		2	1	1	0											
   0		3	1	0	0											
   1		0	1	0	0											
   1		1	1	1	0											
   1		2	1	1	1											
   1		3	1	0	1											
   ...																

Common attributes include the color and alpha Cd(0) Cd(1) Cd(2) Cd(3), texture coordinates uv(0) uv(1) uv(2), and vertex normal N(0) N(1) N(2). See Vertex Attributes for a list of attributes.

Primitives DAT primsdat - DAT with primitive data. The optional index indicates the primitive number, if none is specified, row number will be used. Column headings are required; vertices list the point numbers in order, close indicates whether the primitive is a closed or open curve. Attributes are specified in the same manner as for points. Sample primitive data:

   index	vertices	close	Cd(0)	Cd(1)	Cd(2)	Cd(3)										
   0		0 1 2 3		1	0.2	1	1	1								
   1		4 5 6 7		1	0.2	0.2	0.5	1								
   2		8 9 10 11	1	0.2	0.2	0.2	1									

Common attributes include the color and alpha Cd(0) Cd(1) Cd(2) Cd(3). See Primitive Attributes for a list of attributes.

Detail DAT detaildat - DAT with detail data. Attribute names are specified on the first row and attribute data on the second row. Sample detail data:

   pCaptPath		pCaptData(0)	pCaptData(1)	pCaptData(2)	...											
   /bone1/cregion 	0		3.33333		0		...																

Merge merge - - Specify whether to merge point data or primitive data. This parameter is only enabled when there is an input connected to the SOP.

  • Points points - Merge point data.
  • Vertices vertices -
  • Primitives primitives - Merge primitive data.
  • Detail detail -

Add Float Attributes float - Add a non-standard attribute specified in the point or primitive DAT as a float.

Add Int Attributes int - Add a non-standard attribute specified in the point or primitive DAT as an int. It will not be added if it has already been specified in the Float attributes.

Add String Attributes string - Add a non-standard attribute specified in the point or primitive DAT as a string. It will not be added if it has already been specified in the Float or Int attributes.

Build build - - Specifies how to build geometry.

  • Use Primitive DAT dat - Build geometry using data from the Primitive DAT.
  • Connect All Points all - Connect all points.
  • Connect Every 2 Points pts2 - Connect points in pairs.
  • Connect Every 3 Points pts3 - Connect points in triples.
  • Connect Every 4 Points pts4 - Connect every 4 points together.
  • Connect Every N Points ptsn - Connect every N points together.
  • Polygon with N Rows polyrow - Create a polygon grid with N rows.
  • Polygon with N Columns polycol - Create a polygon grid with N columns.
  • Mesh with N Rows meshrow - Create a mesh grid with N rows.
  • Mesh with N Columns meshcol - Create a mesh grid with N columns.
  • Particle System using All Points particleall - Creates a particle system of points.

N n - Number of points used for building primitives.

Closed U closed - Closed curves in U.

Closed V closedv - Closed curves in V.

Connectivity connect - - Connectivity of polygons.

  • Rows rows - Creates horizontal lines.
  • Columns cols - Creates vertical lines.
  • Rows and Columns rowcol - Both Rows and Columns. Looks like Quads in wireframe display, but all polygons are open (if the primitive type is polygon). Compare them in the Model Editor.
  • Triangles triangles - Build the grid with Triangles.
  • Quadrilaterals quads - Generates sides composed of quadrilaterals (default).
  • Alternating Triangles alttriangles - Generates triangles that are opposed; similar to the Triangles option.

Particle Type prtype - -

  • Render as Lines lines -
  • Render as Point Sprites pointprites -


SOPs
Add • Alembic • Align • Arm • Attribute Create • Attribute • Basis • Blend • Bone Group • Boolean • Box • Bridge • Cache • Cap • Capture Region • Capture • Carve • CHOP to • Circle • Clay • Clip • Convert • Copy • CPlusPlus • Creep • Curveclay • Curvesect • DAT to • Deform • Delete • Divide • Extrude • Facet • File In • Fillet • Fit • Font • Force • Fractal • Grid • Group • Hole • In • Introduction To SOPs id• Inverse Curve • Iso Surface • Join • Joint • Kinect • Lattice • Limit • Line • Line Thick • LOD • LSystem • Magnet • Material • Merge • Metaball • Model • Noise • Null • Object Merge • Oculus Rift • OpenVR • Out • Particle • Point • Polyloft • Polypatch • Polyreduce • Polyspline • Polystitch • Primitive • Profile • Project • Rails • Ray • Rectangle • Refine • Resample • Revolve • Script • Select • Sequence Blend • Skin • Sort • Sphere • Spring • Sprite • Stitch • Subdivide • Superquad • Surfsect • Sweep • Switch • Text • Texture • Torus • Trace • Trail • Transform • Trim • Tristrip • Tube • Twist • Vertex • Wireframe • ZED

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

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

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

A surface type in including polygon, curve (NURBS and Bezier), patch (NURBS and Bezier) and other shapes like sphere, tube, and metaball. and Primitives are part of the , which is a part of a .

Information associated with geometry. and (polygons, NURBS, etc.) can have any number of attributes - position (P) is standard, and optional are normals (N), texture coordinates (uv), color (Cd), etc.