Functions | |
int | Show_Existence (const char *filter) |
int | QShow_Existence (const char *segment, const char *filter) |
int | Show_Existence_By_Key (HC_KEY key, const char *filter) |
int | Show_Existence_Unicode (unsigned short const *filter) |
int | QShow_Existence_Unicode (const char *segment, unsigned short const *filter) |
int | Show_Existence_Unicode_By_Key (HC_KEY key, unsigned short const *filter) |
int Show_Existence | ( | const char * | filter | ) |
A utility routine to determine how much of something exists within a segment, or if it exists at all.
filter | - List of the types of objects to query. |
The Show_(Attribute) routines may complain if they are called on a segment that doesn't have the attribute set. Instead, Show_Existence can be quickly used to test for the attribute's existence. If a "1" is returned, the attribute is set on the segment, and the Show_(Attribute) call is safe.
If filter is equal to the special value "self", Show_Existence() tells whether there is any open segment, and is equivalent to the following:
Begin_Segment_Search (segment) Show_Segment_Count (&count) End_Segment_Search ()
That is, it counts the number of segments, matching the specification string segment (which can contain wildcards) if any such segment exists.
If filter is anything else, Show_Existence() and QShow_Existence() are equivalent to the following:
Begin_Contents_Search (segment, filter) Show_Contents_Count (&count) End_Contents_Search ()
That is, they count the number of such items within segment or within the currently-open segment. Count is then returned as the function value.
As in Begin_Contents_Search(), filter is of the form "type, type", where each type is one of the following:
Show_Existence_By_Key() is almost identical to Show_Existence(), except that the "self" operator is slightly different. If the key is non-negative (i.e., the key value was set with Renumber_Key() ), the "self" operator signifies whether or not the key refers to a valid HOOPS object. This works even if the key refers to something besides a segment. However, if the key is negative, then it is a direct memory reference and it becomes too dangerous to test to see whether it still exists. In this case, Show_Existence_By_Key() will just complain and return.
Additional types (meanings should be self-explanatory) accepted by this function are: "distant light", "local light", "spot light", "area light","includer","styler","style","color","callback","camera","clip region","handedness","selectability","visibility", "window","window frame","color map","driver","driver options","edge pattern","edge weight","face pattern","heuristics","line pattern","line weight","marker size", "marker symbol","metafile","modelling matrix","rendering options","text alignment","text font","text path","text spacing","texture matrix","user value","window pattern", "texture definition","local texture","glyph definition","line pattern definition","line style definition","condition","streaming mode","circle","circular arc", "circular chord","circular wedge","cutting plane","cutting section","light","ellipse","elliptical arc","grid","line","marker","mesh","image","pixel array","polyline", "polygon","shell","string cursor","text","nurbs curve","nurbs surface","cylinder","polycylinder","sphere","include" and "reference geometry".
int QShow_Existence | ( | const char * | segment, | |
const char * | filter | |||
) |
Similar to Show_Existence(), but operates on a given segment rather than the currently open one.
segment | - Name of the segment(s) in which to search. Can include wildcards, multiple segments, etc. | |
filter | - List of the types of objects to be queried. |
int Show_Existence_By_Key | ( | HC_KEY | key, | |
const char * | filter | |||
) |
Similar to Show_Existence(), but operates on an object referenced by an HC_KEY.
key | - A key previously returned from a "K" routine, or a renumbered key. | |
filter | - List of the types of objects to query. |
int Show_Existence_Unicode | ( | unsigned short const * | filter | ) |
A utility routine used to determine whether one or more unicode user options exist within a segment.
filter | - List of the types of objects to query. |
int QShow_Existence_Unicode | ( | const char * | segment, | |
unsigned short const * | filter | |||
) |
Similar to Show_Existence_Unicode(), but operates on a given segment rather than the currently open one.
segment | - Name of the segment(s) in which to search. Can include wildcards, multiple segments, etc. | |
filter | - List of the types of objects to query. |
int Show_Existence_Unicode_By_Key | ( | HC_KEY | key, | |
unsigned short const * | filter | |||
) |
Similar to Show_Existence_Unicode(), but operates on an object referenced by an HC_KEY.
key | - A key previously returned from a "K" routine, or a renumbered key. | |
filter | - List of the types of objects to query. |