L system
|
IntroductionThis page presents a number of scripts that implement a L system that can generate graphics for Maya and RenderMan. Download all code. maya/ |_ scripts/ |_ LMelProcs.mel |_ lsys/ |_ lsystem.py |_ lscriptreader.py |_ lgenerator.py |_ lmel.py |_ mayasocket.py |_ lrib.py |_ lprocedural.py cutter/ |_ archive_tester.rib |_ procedural_tester.rib |_ tree.dat |
Running the L system - Input & Output(s)
The data that "drives" the L system is contained in a .dat file. It specifies the axiom,
the (substitution) rules and the number of times the rules should be applied - the generations.
It also contains values that control a number of other aspects of the L system. For example, a script
called |
|
Generating Graphics for MayaStep 1
Open |
Figure 1 - output via mel |
Generating Graphics using RenderManStep 1
In the ReadArchive "FULL_PATH_TO/tree.rib"
so that the full path to tree.rib is correctly specified.
Execute the Procedural "RunProgram" ["/usr/bin/python FULL_PATH_TO/lprocedural.py" "FULL_PATH_TO/tree.dat, generations 3, angle 20 30"] [-1000 1000 -1000 1000 -1000 1000]
Execute the Procedural "RunProgram" ["/usr/bin/python FULL_PATH_TO/lprocedural.py" "FULL_PATH_TO/tree.dat, rule *G 4"] [-1000 1000 -1000 1000 -1000 1000] |
Figure 2 - output via rib |
Figure 3 - adding data via a procedural |
|
© 2002- Malcolm Kesson. All rights reserved.