Ovis_Group_Create()
Abstract
Creates an Ovis group.
Syntax
Ovis_Group_Create (group_name, comment, parent_group, show_initially, destroy_callback, user_state)
| Argument | Type | Description |
|---|---|---|
group_name |
const char * |
Group name |
comment |
const char * |
Specifies comment |
parent_group |
OvisT_Group * |
Parent group |
show_initially |
OvisT_Boolean |
Specifies whether the group appears initially |
destroy_callback |
OvisT_Group_State_Destroy_Proc |
User-defined procedure used to destroy the data associated with the object and deallocate its memory |
user_state |
void * |
User-defined state associated with the group |
Return Type
OvisT_Group *
Newly created group
Header
ovis_entity.h
Details
This function creates an Ovis group and specifies the attributes of the group. Groups provide the ability to show or hide a set of related entities to avoid having too much graphical information in the animation. Groups can include any number of entities and other groups. There is a root group that cannot be destroyed. Showing a group will show its entities and child groups (recursively showing). Hiding a group will hide its entities and child groups (recursively hiding).
Example
OvisT_Group * group;
group = Ovis_Group_Create ("friendly forces",
"Hold entities belonging to blue group",
OvisC_True, OPC_NIL, OPC_NIL, OPC_NIL);
Errors
- No group name provided.
Reference
- Use the function
Ovis_Root_Group_Get()to discover the root group. - Use the function
Ovis_Group_Destroy()to destroy a group.