Go to: Related nodes. Attributes.

                This node contains attributes and routines for
                creating toon style outlines around objects.

Node nameParentsClassificationMFn typeCompatible function sets
pfxToonpfxGeometrypfxToonkPfxToonkBase
kNamedObject
kDependencyNode
kDagNode
kShape
kPfxGeometry
kPfxToon

Related nodes

strokeGlobals, brush, pfxGeometry, stroke, pfxHair

Attributes (84)

Attribute quick index omitted (too many attributes to show them all).

Long name (short name)TypeDefaultFlags
inputSurface (ins) compoundn/aarrayoutputinputconnectable
This is the input multi-attribute for the surfaces getting toon outlines. Both the geometry and world matrix are connected.
surface (srf) meshNULLoutputinputconnectable
Input mesh
inputWorldMatrix (iwm) matrixidentityoutputinputconnectable
Input matrix from mesh or surface
displayInViewport (div) booltrueoutputinputconnectablestorablekeyable
If on, then lines are displayed in the modelling viewports.
profileLines (pln) enum1outputinputconnectablestorablekeyable
If not off then lines are generated along the silhoutte of objects. If Paint Effects lines are used then curves following the outline are constructed. These lines are view relative and thus must are rebuilt when the view changes. If Offset Mesh is used, then a duplicate of the input mesh is constructed that is offset along the surface normal by the line width. By making this mesh both single sided and reversed a shell is formed that creates a silhoutte when rendered with the input mesh. This has the advantage of built in thick thin line properties that are stable when animated. It also has the advantage of not needing to be updated when the view changes. It will also appear in raytraced reflections and refractions.
creaseLines (cln) booltrueoutputinputconnectablestorablekeyable
If on, then lines are generated along internal hard edges.
borderLines (bln) enum1outputinputconnectablestorablekeyable
This allows one to generated lines along boundaries. Open Edges are considered to be edges that are shared by only one face. This can be used to provide lines around the border of a simple plane, for example. Profile lines do not handle this sort of edge, which only occurs when the surface is not fully closed. Shader boundary edges are where the faces attached to the edge do not share the same shader.
intersectionLines (iln) boolfalseoutputinputconnectablestorablekeyable
If on, then lines are generated where surfaces intersect.
selfIntersect (sei) boolfalseoutputinputconnectablestorablekeyable
If on, then lines are generated where surfaces intersect themselves.
lineWidth (lwd) double0.1outputinputconnectablestorablekeyable
This controls the global width of the profile, crease and boundary lines.
lineWidthMap (lwm) double0.5outputinputconnectablestorablekeyable
This attribute can be used to vary line width with a 2D texture map. This attributes scales the currently defined line width, but by 2 times the lineWidthMap value, so that a value of 0.5 has no effect. Where the texture value was 0.25 the line width would be half of the lineWidth attribute value and where the value is 1.0 the value would be double. Values outside the zero to one range can also be used( for file textures this generally requires increasing the alpha gain on the texture ). The texture is mapped into uv space of the surface the lines are on. In addition to thick and thin effects, one can also block line formation entirely in places by using a zero texture value. Note that 3D, projective 2D, and environment textures are not currently supported.
lineOpacity (lop) double1.0outputinputconnectablestorablekeyable
This controls the opacity of the profile, crease and boundary lines. An opacity of 0 is fully transparent and an opacity of 1 is fully opaque.
lineOpacityMap (lpm) double1.0outputinputconnectablestorablekeyable
This attribute can be used to vary the line opacity with a 2D texture map. This attributes scales the currently defined line opacity, so where the texture value was 0.5 the line opacity would be half of the lineOpacity attribute value. The texture is mapped into uv space of the surface the lines are on. Note that 3D, projective 2D, and environment textures are not currently supported.
localOcclusion (lcl) enum0outputinputconnectablestorablekeyable
If Line Surface is used then lines will be clipped where they are hidden by the surface they are created from. If All Toon Surfaces is used then lines will be clipped where they are hidden by any of the surfaces that are currently assigned these toon lines. This occlusion is generally meant to augment the line occlusion by the normal paint effect render, or orther renders if convert toon to poly is used. With paint effects renders, the depthBias attribute may be useful when combined with local occlusion.
occlusionTolerance (otl) double0.01outputinputconnectablestorablekeyable
This is an amount in worldspace that lines are moved towards the camera when testing depth for local occlusion. A small value is required to avoid artifacts where the surface self occludes lines.
depthBias (dbs) double0.0outputinputconnectablestorablekeyable
This is an amount in worldspace that lines are moved towards the camera when rendering. This is useful in avoiding artifacts with depth occlusion by the surface the lines are on.
profileLineWidth (plw) double1.0outputinputconnectablestorablekeyable
This is a relative scale of the width of the profile, or silhoutte lines.
creaseLineWidth (clw) double1.0outputinputconnectablestorablekeyable
This is a relative scale of the width of the crease, or hard edge lines.
borderLineWidth (blw) double1.0outputinputconnectablestorablekeyable
This is a relative scale of the width of the border, or boundary lines.
intersectionLineWidth (ilw) double1.0outputinputconnectablestorablekeyable
This is a relative scale of the width of the intersection lines.
lineOffset (lof) double0.0outputinputconnectablestorablekeyable
This offsets lines along the surface normal. The amount of offset is relative to the line width, a value of 1.0 having the line just touch the surface. With a value of 0 the line is half intersecting the surface.
lineOffsetMap (lom) double0.0outputinputconnectablestorablekeyable
This attribute can be used to vary line offset with a 2D texture map. If a noisy texture is used this can create a wiggly line. This attributes scales the currently defined line offset, so where the texture value was 0.5 the line offset would be half of the lineOffset attribute value. The texture is mapped into uv space of the surface the lines are on. Note that 3D, projective 2D, and environment textures are not currently supported.
lightingBasedWidth (lbw) double0.0outputinputconnectablestorablekeyable
The width is scaled by the diffuse light intensity. Brighter regions will be thinner. Shadowed and dark regions will have full width tubes. Using negative values can have the reverse effect. The lighting used is a diffuse illumination that is relative to the local surface normal.
occlusionWidthScale (ows) booltrueoutputinputconnectablestorablekeyable
OcclusionWidthScale is useful for avoiding aliasing artifacts along the inside edge of lines. The paint effects brush stamp radius is scaled down based on the average occlusion within the stamp region, rather than occluding each pixel of the stamp draw. This allows lines to have their center on the object's profile boundary. Otherwise the line on the inside edge gets occluded by the object, and thus only the outer half of the line is visible. Paint Effects relies on the the depth buffer from the scanline phase of the render for occlusion, however there is only one depth value per pixel, which creates a challenge for good antialiasing. Using Occlusion Width Scale gets around some of these aliasing problems, although very thick lines may in places bite into objects more than desired. Also in some unusual situations it may cause a blobby quality where there are sudden changes in occlusion. Note that if a brush is assigned the toon line, then the setting for occlusion width scale on the brush node will override the setting on the toon node.
depthOffset (dff) double0.0outputinputconnectablestorablekeyable
This offsets profile lines along the view direction. This can help give lines a more graduated width where the profile is internal to the object.
creaseAngleMin (amn) double20.0outputinputconnectablestorablekeyable
This is the start angle in degrees between faces beyond which creasing forms. Line thickness can be graduated between zero width at the min angle and going to full thickness at the max. At an angle of zero all edges will be drawn, if hardCreasesOnly is OFF.
creaseAngleMax (amx) double90.0outputinputconnectablestorablekeyable
This is the angle in degrees between faces beyond which crease line thickness is the maximum. At an angle of zero all edges will be drawn, if hardCreasesOnly is OFF.
hardCreasesOnly (hco) booltrueoutputinputconnectablestorablekeyable
If on, then creases are only generated along hardened edges.
backfacingCreases (bfc) booltrueoutputinputconnectablestorablekeyable
If on, then creases are generated on surfaces that face away from the view.
intersectionAngleMin (imn) double1.0outputinputconnectablestorablekeyable
This is the start angle in degrees between faces beyond which intersection lines form. Line thickness can be graduated between zero width at the min angle and going to full thickness at the max. At an angle of zero all intersecting edges will be drawn. By varying the min max intersection angle one can avoid lines along flush intersections, yet still have lines where the intersection angle is steeper.
intersectionAngleMax (imx) double1.0outputinputconnectablestorablekeyable
This is the angle in degrees between faces beyond which intersection line thickness is the maximum. At an angle of zero all intersection lines will be drawn at full thickness.
smoothProfile (spf) booltrueoutputinputconnectablestorablekeyable
If on then the profile is computed based on the interpolated normals. If off the profile curve will exist only on polygon edges. The off state guarantees that the profile will be always at the exact visible boundary, although it will jump in discreet steps as the view changes or the object deforms. With smooth profiles ON the profile changes in a smooth continuous fashion, but may creep in from edges in places where the surface is crudely triangulated.
tighterProfile (tpf) boolfalseoutputinputconnectablestorablekeyable
If on then smooth profiles will be a bit closer to the mesh profile edge, particularily in cases where the vertex normals do not match an edge orientation well. A primitive cone is a good example of this situation. Deriving the profile from the vertex normals does not work well in this case, because the normals define more of a hump than a pointed cone. For a cone the tighter profile method will push the profile about halfway closer to the the point of the cone. To fit closer than this, increase the subdivisions on the cone, or turn off smooth profile.
curvatureModulation (cmo) boolfalseoutputinputconnectablestorablekeyable
This varies the width of lines relative to the 3d curvature of the line. When enabled the curvatureWidth graph controls how curvature affects line width. The input position sampled from the curvatureWidth graph is the the curvature, where the left of the graph is zero curvature( straight ) and the right is fully bent at a 180 degree angle. The output value of the graph (vertical position) is then used to determine a scale factor for the current width. Thus if the graph is a horizontal line with a value of 1.0 the line width is unchanged. Where the graph is zero the line width will be zero.
curvatureWidth (cwd) compoundn/aarrayoutputinputconnectablestorablekeyable
When curvatureModulation is enabled the curvatureWidth graph controls how curvature affects line width. The input position sampled from the curvatureWidth graph is the the curvature, where the left of the graph is zero curvature( straight ) and the right is fully bent at a 180 degree angle. The output value of the graph (vertical position) is then used to determine a scale factor for the current width. Thus if the graph is a horizontal line with a value of 1.0 the line width is unchanged. Where the graph is zero the line width will be zero.
curvatureWidth_Position (cwdp) float0.0outputinputconnectablestorablekeyable
Position of ramp value on normalized 0-1 scale
curvatureWidth_FloatValue (cwdfv) float0.0outputinputconnectablestorablekeyable
Ramp value at the sibling position
curvatureWidth_Interp (cwdi) enum0outputinputconnectablestorablekeyable
Ramp Interpolation controls the way the intermediate values are calculated. The values are:
    None: No interpolation is done; the different colors just show up as different bands in the final texture.

    Linear: The values are interpolated linearly in RGB color space.

    Smooth: The values are interpolated along a bell curve, so that each color on the ramp dominates the region around it, then blends quickly to the next color.

    Spline: The values are interpolated with a spline curve, taking neighboring indices into account for greater smoothness.

profileWidthModulation (pwm) double0.0outputinputconnectablestorablekeyable
This varies the width of lines relative to the view angle.
creaseWidthModulation (cwm) double0.0outputinputconnectablestorablekeyable
This varies the width of lines relative to the view angle.
borderWidthModulation (bwm) double0.5outputinputconnectablestorablekeyable
This varies the width of lines relative to the view angle.
intersectionWidthModulation (imd) double0.0outputinputconnectablestorablekeyable
This varies the width of lines relative to the view angle.
profileBreakAngle (pba) double180.0outputinputconnectablestorablekeyable
This is the angle in degrees beyond which profile lines are broken. Line segments that are less than this angle with respect to each other are joined into lines. At a value of 0 all lines will be only one segment long. At a value of 180 all adjacent segments will be joined together into lines.
creaseBreakAngle (cba) double80outputinputconnectablestorablekeyable
This is the angle in degrees beyond which crease lines are broken. Line segments that are less than this angle with respect to each other are joined into lines. At a value of 0 all lines will be only one segment long. At a value of 180 all adjacent segments will be joined together into lines.
borderBreakAngle (bba) double80.0outputinputconnectablestorablekeyable
This is the angle in degrees beyond which border lines are broken. Line segments that are less than this angle with respect to each other are joined into lines. At a value of 0 all lines will be only one segment long. At a value of 180 all adjacent segments will be joined together into lines.
intersectionBreakAngle (iba) double180.0outputinputconnectablestorablekeyable
This is the angle in degrees beyond which intersection lines are broken. Line segments that are less than this angle with respect to each other are joined into lines. At a value of 0 all lines will be only one segment long. At a value of 180 all adjacent segments will be joined together into lines.
removeFlushBorders (rfb) boolfalseoutputinputconnectablestorablekeyable
This will removes borders where meshes touch and have matching normals.
flushTolerance (tfl) double0.01outputinputconnectablestorablekeyable
This is the max distance boundary cvs can be from each other when suppressing flush or common border lines.
flushAngleMax (fmx) double4.0outputinputconnectablestorablekeyable
This is the max angle in degrees that boundary vertex normals can be from each other when suppressing flush or common border lines.
lineEndThinning (let) double0.0outputinputconnectablestorablekeyable
This controls the distance from line ends beyond which they become fully thick. Depending on the object one may need to lower the Break Angle values in order to see open line ends. For most surfaces the profile lines form closed lines with no open ends. The continuation of the profile is sometimes hidden where it goes behind the object. It may thus look like it has open ends event though it is closed and will thus not show the effect of line end thinning. Crease lines are more likely to show open ends than profiles or borders. One can use the break angles to create open ends where the line curves strongly.
lineExtend (lex) double0.0outputinputconnectablestorablekeyable
This extends the ends of lines so they cross at corners rather than simply intersecting. Line Extend simulates a pencil drafting style of line. Depending on the object one may need to lower the Break Angle values in order to see open line ends. For most surfaces the profile lines form closed lines with no open ends. The continuation of the profile is sometimes hidden where it goes behind the object. It may thus look like it has open ends event though it is closed and will thus not show the effect of Line Extend. Crease lines are more likely to show open ends than profiles or borders. One can use the break angles to create open ends where the line curves strongly.
resampleProfile (rpf) boolfalseoutputinputconnectablestorablekeyable
The points along the profile are typically spaced at irregular distances, depending on the surface geometry. This is especially noticable if one assigns a brush with tubes ON to the toon line, where the tubes will jump around as the scene is animated. Enabling this causes the profile lines to be resampled at a uniform cv spacing, resulting in smoother strokes that jump less. The resample spacing needs to be small enough to avoid rounding corner edges.
resampleCrease (rcr) boolfalseoutputinputconnectablestorablekeyable
The points along the crease are normally spaced according to the size of poly edges. For simple objects this may not provide enough cvs for effects like line end thinning. Resample crease provides the ability to sample the crease lines with fewer or more cvs, as well as to fix the worldspace distance between curve cvs. Note that this may make crease lines twitch when animated if screenspace resampling is not zero. The resample spacing needs to be small enough to avoid rounding corner edges.
resampleBorder (rbd) boolfalseoutputinputconnectablestorablekeyable
The points along the border are normally spaced according to the size of poly edges. For simple objects this may not provide enough cvs for effects like line end thinning. Resample border provides the ability to sample the border lines with fewer or more cvs, as well as to fix the worldspace distance between curve cvs. Note that this may make border lines twitch when animated if screenspace resampling is not zero. The resample spacing needs to be small enough to avoid rounding corner edges.
resampleIntersection (rin) boolfalseoutputinputconnectablestorablekeyable
The points along the intersection are typically spaced at irregular distances. This is do to the way that triangles overlap along the edge. This is especially noticable if one assigns a brush with tubes ON to the toon line, where the tubes will jump around as the scene is animated. Enabling Resample Intersection causes the profile lines to be resampled at a uniform cv spacing, resulting in smoother strokes that jump less. The resample spacing needs to be small enough to avoid rounding corner edges.
maxSegmentLength (msl) double0.5outputinputconnectablestorablekeyable
This is a maximum distance that is allowed between cvs on profiles when resample profile is ON. If this is small there may be many cvs on a profile curve. If this value is very large the profile curve will have its original number of cvs, but uniformly distributed across the original curve. One may have rounded corners if the max segment length is not low enough.
minSegmentLength (mns) double0.0outputinputconnectablestorablekeyable
This is the smallest distance that is allowed between cvs on profiles when resample profile is ON. If this is large the profile curve may be very crudely sampled. It is useful if one wants an output, for example to polymesh, where the number of segments is kept to a minimum. Also when combined with screenspace resampling it can be used to simplify distant profiles.
screenSpaceResampling (ssr) double0.0outputinputconnectablestorablekeyable
This controls the degree to which outline curve resampling is done in screenspace. When this is 1.0 the segments will be a fixed distance apart in screenspace. When it is 0.0 the distances are fixed in worldspace. Between 1.0 and 0.0 these two sampling methods are interpolated. This can be used to have profile curves become simpler with distance. Also if one has a brush with tubes = on assigned to the toon line the number of tubes will reduce with distance when this is greater than zero.
pfxRandomize (prz) boolfalseoutputinputconnectablestorablekeyable
If this is ON then each curve is given a new random seed for paint effects. This requires that one have a pfx brush with tubes=ON assigned to the toon line. Profiles line tubes may jump around if this is ON when animated.
screenspaceWidth (spw) boolfalseoutputinputconnectablestorablekeyable
whether or not to make the line width constant for different depths from the view
distanceScaling (dsl) double0.0outputinputconnectablestorablekeyable
This controls the amount that the distance from the eye affects the tube width when screenSpace width is enabled. At a value of 0.0 the width is constant while at a value of 1.0 it behaves as if screenspace width is OFF.
minPixelWidth (mpw) double0.0outputinputconnectablestorablekeyable
When screenspace width is enabled this controls the smallest width a stroke can be in pixels. It is useful for toon lines when one wishes to avoid very thin lines.
maxPixelWidth (mxp) double1000.0outputinputconnectablestorablekeyable
When screenspace width is enabled this controls the largest width a stroke can be in pixels. It is useful for toon lines when one wishes to avoid very fat lines.
profileColor (pcl) float3outputinputconnectablestorable
input color for profiles This may be textured with 2D textures. The line color is then derived based on the color of the texture mapped to the surface. Note that 3D, projective 2D, and environment textures are not currently supported, however one could convert the toon lines to a poly mesh then apply a shader with 3D textures to the result.
profileColorR (pcr) float0.0outputinputconnectablestorablekeyable
profile color red value
profileColorG (pcg) float0.0outputinputconnectablestorablekeyable
profile color green value
profileColorB (pcb) float0.0outputinputconnectablestorablekeyable
profile color blue value
creaseColor (ccl) float3outputinputconnectablestorable
input color for creases This may be textured with 2D textures. The line color is then derived based on the color of the texture mapped to the surface. Note that 3D, projective 2D, and environment textures are not currently supported, however one could convert the toon lines to a poly mesh then apply a shader with 3D textures to the result.
creaseColorR (ccr) float0.0outputinputconnectablestorablekeyable
crease color red value
creaseColorG (ccg) float0.0outputinputconnectablestorablekeyable
crease color green value
creaseColorB (ccb) float0.0outputinputconnectablestorablekeyable
crease color blue value
borderColor (bcl) float3outputinputconnectablestorable
input color for borders This may be textured with 2D textures. The line color is then derived based on the color of the texture mapped to the surface. Note that 3D, projective 2D, and environment textures are not currently supported, however one could convert the toon lines to a poly mesh then apply a shader with 3D textures to the result.
borderColorR (bcr) float0.0outputinputconnectablestorablekeyable
border color red value
borderColorG (bcg) float0.0outputinputconnectablestorablekeyable
border color green value
borderColorB (bcb) float0.0outputinputconnectablestorablekeyable
border color blue value
intersectionColor (icl) float3outputinputconnectablestorable
input color for intersections This may be textured with 2D textures. The line color is then derived based on the color of the texture mapped to the surface. Note that 3D, projective 2D, and environment textures are not currently supported, however one could convert the toon lines to a poly mesh then apply a shader with 3D textures to the result.
intersectionColorR (icr) float0.0outputinputconnectablestorablekeyable
intersection color red value
intersectionColorG (icg) float0.0outputinputconnectablestorablekeyable
intersection color green value
intersectionColorB (icb) float0.0outputinputconnectablestorablekeyable
intersection color blue value
outColor (ocl) float30.0, 0.0, 0.0outputconnectable
The output profile color. This is currently a simple pass-through from the profile color.
outColorR (ocr) float0.0outputconnectable
The red component of the profile output color.
outColorG (ocg) float0.0outputconnectable
The green component of the profile output color.
outColorB (ocb) float0.0outputconnectable
The blue component of the profile output color.
outProfileMesh (opm) meshNULLarrayoutputconnectable
This is an output array of meshes matching the input meshes, but offset along the normal by the line width. By enabling opposite siding and backface removal these meshes create a profile outline about the original input meshes. Unlike pfx profile lines these lines are formed by the render of the two meshes, and do not need to be updated when the view changes. If offsetMeshProfile lines are not enabled then these output connections will evaluated to empty meshes.