This tutorial will help you getting started with GenShade. It presents
the simplest shader breeding methods, which could be the fastest and most
effective in some cases. This tutorial assumes that you are familiar with
the concepts and tools presented in tutorials one and two.
1. Project Loading
-
Create a working directory:
% mkdir myproject
% cd myproject
-
Enter the software, hit File->Load Project ..., and bring up (1):
/usr/local/genshade/prman/examples/gs_01012000_03_sur_stree_01.prj
The GUI looks like:
GenShade Graphical User Interface (GUI) showing the loaded project
2. First Generation
-
Select two parents option from the breeding method
option at the tool bar
-
Select sphere option from the geometry option
at the tool bar.
Tool Bar
-
Hit Generation->Generate Once..., submenu.
The first generation begins which should not take more than few minutes
creating 27 new shaders (2). The text window provides information about
generation progress (3):
-
- creating shader data
-
- compiling shaders
-
- rendering and loading images
Images of new children shaders are displayed as soon as they are rendered.
Every pair of parents generates two children, the first child is
displayed at:
-
- child 1 cell of the Parent Images Area, and
-
- one of the odd numbered cells of the Current Population Pool,
for
example C1.
The second child is displayed at:
-
- child 2 cell of the Parent Images Area,
and
-
- one of the even numbered cells of the Current Population Pool,
for
example C2.
-
(cell C0 in this setting displays a copy of the first parent)
-
Pick your favorite images of shaders and copy them into the Storage
Pool
(please refer to tutorial 2: Moving Around for details about doing
so)
first generation
(results vary depending on the generation parameters used)
3. Second Generation
-
Copy child C1 image and data, from the current population
pool to parent 1 cell
-
Copy child C20 image and data, from the current population
pool to parent 2 cell
(please refer to tutorial 2: Moving Around for details about doing
so)
-
Hit Generation->Generate Once ... submenu.
When the generation is complete, pick your favorite images of shaders
and copy them into the Storage Pool
second generation
(results vary depending on the generation parameters used)
4. Third Generation
-
Copy child C5 image and data, from the current population
pool to parent 1 cell
-
Copy child C7 image and data, from the current population
pool to parent 2 cell
-
Hit Generation->Generate Once ... submenu.
-
When the generation is complete, pick your favorite images of shaders and
copy them into the Storage Pool
third generation
5. Fourth Generation
-
Copy child C18 image and data, from the current population
pool to parent 1 cell
-
keep parent 2 unchanged.
-
Hit Generation->Generate Once ... submenu.
-
When the generation is complete, pick your favorite images of shaders and
copy them into the Storage Pool
fourth generation
6. Image Viewing
To view images
of the shaders generated so far and their parents:
-
Select unsorted children option from the Image Selection
Source at the Image Display Control Panel
-
move the Generation Number Slider at the Image Display
Control Panel to the far left to display 0
A portion of image display control panel
-
click on step forward, which is the second repeat button
from the right of the Image Display Control Panel to display images
of generation # 1.
step forward repeat button
-
repeat the previous step to display images of generations # 2 to 4
-
Select parents option from the Image Selection Source at
the Image Display Control Panel (4)
A portion of image display control panel
-
repeat previous steps using the play forward repeat button
instead
play forward repeat button
Parents of fourth generation children
7. Fifth generation using one-parent breeding
Lets us assume that we are happy with the results obtained so far and that
we would like to fine tune our favorite shader:
-
Copy child C15 image and data, from the fourth generation
current population pool to parent 1 cell
-
keep parent 2 unchanged.
-
Select one parent option from the pool option
at the tool bar
-
(Only parent 1 will be selected for mutation, parent 2 will
be ignored)
-
Using the Frequently Used Generation Parameters, the sliders
to the right of the Parent Images Area, change the following:
-
- change VM (Variable Mutation) to 0.2
-
- change NM (Node Mutation) to 0.2
-
These parameters will allow the generation of more diverse children.,
-
Hit Generation->Generate Once ... submenu.
When the generation is complete, pick your favorite images of shaders
and copy them into the Storage Pool
Fifth generation
-
Hit File->Save Storage Database ... submenu,
select the name of your new shader database, and click OK.
The new shader database can be used for:
-
- further generations
-
- future generations
-
- your project
Here is a selection of the stored shaders:
A selection of the stored shaders
Notes:
(1) Your sysadmin may have installed the software somewhere other
than /usr/local. If so, look at your $GENSHADE_DIR variable, and
use that instead of /usr/local/genshade in the above
example.
(2) First Generation, in this tutorial, took 3.1 minutes on a
SGI O2 workstation with 256 MB of RAM
(3) Detailed information can be found at the unix shell or log files.
(4) another useful tool is to use Generation->Select parents.
This will display the parents of next generation without actually executing
the full generation. This will help you decide if you would like to go
further and select Generation->Generate ... to execute the
full generation. When Using two parents or one parent
breeding methods, this tool may not be important since you already know
what the parents are. But when using other breeding methods, this tool
may be very important.