| 21 |
|
#define DO_NCMDS 10 /* number of object display commands */ |
| 22 |
|
|
| 23 |
|
/* commands entered on stdin only */ |
| 24 |
< |
#define DO_INIT {"load","unload","xform","move","unmove","dup",\ |
| 24 |
> |
#define DO_INIT {"load","clear","xform","move","unmove","dup",\ |
| 25 |
|
"show","light","hide","object"} |
| 26 |
|
|
| 27 |
|
/******************************************************************* |
| 44 |
|
dobj_command(cmd, args) : check/run object display command |
| 45 |
|
char *cmd, *args; : command name and argument string |
| 46 |
|
|
| 47 |
< |
Check to see if this is an object display command, and return the command |
| 48 |
< |
number after running it if it is, or -1 if it isn't. Error messages should |
| 47 |
> |
Check to see if this is an object display command, and return -1 if |
| 48 |
> |
it isn't. If it is a valid command that results in some visible |
| 49 |
> |
change, return non-zero, otherwise return 0. Error messages should |
| 50 |
|
be printed with error(COMMAND,err). |
| 51 |
|
|
| 52 |
|
|
| 62 |
|
then all visible objects are checked, but the name is not returned. |
| 63 |
|
|
| 64 |
|
|
| 65 |
< |
void |
| 65 |
> |
int |
| 66 |
|
dobj_render() : render visible objects to OpenGL |
| 67 |
|
|
| 68 |
|
Renders all display objects using OpenGL, assuming desired view has |
| 69 |
|
been set. This routine also assumes that the tone-mapping library |
| 70 |
|
is being used to set exposure, and it queries this information to |
| 71 |
< |
adjust light sources as necessary for illuminated objects. |
| 71 |
> |
adjust light sources as necessary for illuminated objects. Returns |
| 72 |
> |
the number of objects rendered. |
| 73 |
|
|
| 74 |
|
|
| 75 |
|
void |