$subd: Difference between revisions
Jump to navigation
Jump to search
Tip:The smoothness can be adjusted using the console variable
Tip:It works only in Alien Swarm and Source Filmmaker.
Confirm:Works in games other than Alien Swarm and Source Filmmaker?
Warning:Studiomdl will crash if any triangles are present in the model.
($displacementmap note) |
No edit summary |
||
Line 8: | Line 8: | ||
{{tip|The smoothness can be adjusted using the [[ConVar|console variable]] <code>mat_tessellationlevel <1-16></code>, with higher values rendering more polygons.}} | {{tip|The smoothness can be adjusted using the [[ConVar|console variable]] <code>mat_tessellationlevel <1-16></code>, with higher values rendering more polygons.}} | ||
{{tip|It works only in [[Alien Swarm]] and [[Source Filmmaker]].}} | |||
{{confirm|Works in games other than [[Alien Swarm]] and [[Source Filmmaker]]?}} | {{confirm|Works in games other than [[Alien Swarm]] and [[Source Filmmaker]]?}} |
Revision as of 07:40, 13 November 2022
The QC command $subd
is used to mark a model to be tessellated in run-time. This can be used to make models appear smoother than they actually are.
It also is needed to make $displacementmap work.

mat_tessellationlevel <1-16>
, with higher values rendering more polygons.


$subd
only works with quads and n-gons with more than 3 edges. This effectively makes the SMD format unusable, meaning you have to use the DMX format, as SMD only supports triangles. The SMD format can still be used for animations, though.Syntax
$subd
Note that $subd must be placed before your model line.
Example
$modelname "example/subdivision.mdl" $cdmaterials "example/subdivision" $subd $body test "subdivison.dmx" $sequence idle "subdivision_idle.smd"