Quesa.h
Discussion
Declares the fundamental Quesa types and functions.
Functions
( TQ3Status ) Q3Bitmap_Empty (
TQ3Bitmap *bitmap
);
Discussion
Release the memory used by a TQ3Bitmap.
Should be used to release the data used by TQ3Bitmaps returned by
Quesa. You should not call Q3Bitmap_Empty on TQ3Bitmaps whose
image data was allocated by you.
Parameter Descriptions
- bitmap
- The TQ3Bitmap whose image data should be released.
- function result
- Success or failure of the operation.
( TQ3Boolean ) Q3Bitmap_GetBit (
const TQ3Bitmap *theBitmap,
TQ3Uns32 x,
TQ3Uns32 y
);
Discussion
Get the status of a bit within a bitmap.
This function is not available in QD3D.
Parameter Descriptions
- theBitMap
- The bitmap to query.
- x
- The x coordinate of the pixel to query.
- y
- The y coordinate of the pixel to query.
- function result
- The status of the bit.
( TQ3Uns32 ) Q3Bitmap_GetImageSize (
TQ3Uns32 width,
TQ3Uns32 height
);
Discussion
Determine how much image data would be required for a TQ3Bitmap.
Returns the smallest block of memory that could hold a bitmap
with the specified dimensions.
Parameter Descriptions
- width
- The proposed width of the bitmap.
- height
- The proposed height of the bitmap.
- function result
- The number of bytes needed for the bitmap.
( TQ3Status ) Q3Bitmap_SetBit (
TQ3Bitmap *theBitmap,
TQ3Uns32 x,
TQ3Uns32 y,
TQ3Boolean theState
);
Discussion
Set the status of a bit within a bitmap.
This function is not available in QD3D.
Parameter Descriptions
- theBitMap
- The bitmap to update.
- x
- The x coordinate of the pixel to update.
- y
- The y coordinate of the pixel to update.
- theState
- The new state for the pixel.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3Exit (void);
Discussion
Shuts down Quesa, and releases any resources allocated by the library.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3GetReleaseVersion (
TQ3Uns32 *releaseRevision
);
Discussion
Returns the revision of the installed Quesa software in the format of the
first four bytes of a Macintosh 'vers' resource.
The four bytes contain 1) the major revision level, 2) the minor revision,
3) the development stage, and 4) the prerelease revision level, respectively.
The three revision levels are each represented in binary coded decimal.
The development stage can be development (0x20), alpha (0x40), beta (0x60)
or release (0x80).
For example, if the revision is 1.61a23 (= 1.6.1a23), returns 0x01614023.
For more information, see the description of the 'vers' resource
in the book Inside Macintosh: Macintosh Toolbox Essentials.
Note that unlike QD3D, Quesa allows Q3GetReleaseVersion to be called
outside of a Q3Initialize/Q3Exit block.
Parameter Descriptions
- releaseRevision
- Receives the revision of Quesa.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3GetVersion (
TQ3Uns32 *majorRevision,
TQ3Uns32 *minorRevision
);
Discussion
Returns the major and minor revision levels of the installed
Quesa software.
For example, if the revision is 1.6a23 (= 1.6.0a23), returns 1
as the major revision level and 6 as the minor revision level:
The final 0 in the minor revision level is omitted.
If the revision is 1.61a23 (= 1.6.1a23), returns 1 as the major
revision level and 61 as the minor revision level.
Note that unlike QD3D, Quesa allows Q3GetVersion to be called
outside of a Q3Initialize/Q3Exit block.
Parameter Descriptions
- majorRevision
- Receives the major revision level of Quesa.
- minorRevision
- Receives the minor revision level of Quesa.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3Initialize (void);
Discussion
Initialises Quesa.
Only Q3IsInitialized, Q3GetVersion, and Q3GetReleaseVersion may be
called before the Quesa library is initialised.
- function result
- Success or failure of the operation.
( TQ3Boolean ) Q3IsInitialized (void);
Discussion
Tests to see if Quesa has been initialised or not.
- function result
- True or false as Quesa has been initialised or not.
( TQ3Status ) Q3ObjectHierarchy_EmptySubClassData (
TQ3SubClassData *subClassData
);
Discussion
Release the memory allocated by a previous call to
Q3ObjectHierarchy_GetSubClassData.
Parameter Descriptions
- subClassData
- The sub-class data to release.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3ObjectHierarchy_GetStringFromType (
TQ3ObjectType objectClassType,
TQ3ObjectClassNameString objectClassString
);
Discussion
Returns the class name string for a class identified by a class type.
Parameter Descriptions
- objectClassType
- The class type of the class to locate.
- objectClassString
- Receives the class name string of the class.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3ObjectHierarchy_GetSubClassData (
TQ3ObjectType objectClassType,
TQ3SubClassData *subClassData
);
Discussion
Return the immediate sub-classes of a class.
The data returned must be released with a subsequent call to
Q3ObjectHierarchy_EmptySubClassData.
Parameter Descriptions
- objectClassType
- The class type of the class to query.
- subClassData
- Receives the immediate sub-classes of the class.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3ObjectHierarchy_GetTypeFromString (
const TQ3ObjectClassNameString objectClassString,
TQ3ObjectType *objectClassType
);
Discussion
Returns the class type for a class identified by a class name string.
Parameter Descriptions
- objectClassString
- The class name of the class to locate.
- objectClassType
- Receives the class type of the class.
- function result
- Success or failure of the operation.
( TQ3Boolean ) Q3ObjectHierarchy_IsNameRegistered (
const char *objectClassName
);
Discussion
Check to see if a class is registered with Quesa.
Parameter Descriptions
- majorRevision
- The class name of the class to check.
- function result
- True or false as the class is registered or not.
( TQ3Boolean ) Q3ObjectHierarchy_IsTypeRegistered (
TQ3ObjectType objectClassType
);
Discussion
Check to see if a class is registered with Quesa.
Parameter Descriptions
- objectClassType
- The class type of the class to check.
- function result
- True or false as the class is registered or not.
( TQ3Status ) Q3Object_AddElement (
TQ3Object object,
TQ3ElementType theType,
const void *data
);
Discussion
Add an element to an object.
Same as Q3Shape_AddElement, except that the object is not
required to be a shape or set.
If the object is Shared, this operation will increment the object's edit index.
This function is not available in QD3D.
Parameter Descriptions
- object
- The object to update.
- theType
- The type of the element data.
- data
- The element data.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3Object_CleanDispose (
TQ3Object *theObject
);
Discussion
Cleanly disposes of a Quesa object.
If theObject is not NULL, invokes Q3Object_Dispose to decrement the object
reference count then clears the supplied pointer to prevent stale references.
Equivalent to:
if (theObject != NULL)
{
Q3Object_Dispose(theObject);
theObject = NULL;
}
This function is not available in QD3D.
Parameter Descriptions
- theObject
- The object to dispose (may be NULL).
- function result
- Success or failure of the operation.
( TQ3Status ) Q3Object_ClearElement (
TQ3Object object,
TQ3ElementType theType
);
Discussion
Empty an object of a particular type of element.
Same as Q3Shape_ClearElement, except that the object is not
required to be a shape or set.
If the object is Shared, this operation will increment the object's edit index.
This function is not available in QD3D.
Parameter Descriptions
- object
- The object to update.
- theType
- The element type to remove.
- function result
- Success or failure of the operation.
( TQ3Boolean ) Q3Object_ContainsElement (
TQ3Object object,
TQ3ElementType theType
);
Discussion
Check to see if an object contains an element of a given type.
Same as Q3Shape_ContainsElement, except that the object is not
required to be a shape or set.
This function is not available in QD3D.
Parameter Descriptions
- object
- The object to query.
- theType
- The type of the element data to look for.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3Object_Dispose (
TQ3Object object
);
Discussion
Disposes of a Quesa object.
Most types of TQ3Object are reference-counted. This function
decrements the reference count of the object. When the reference count
falls to 0, the object is deleted.
When used on a non-reference-counted object such as a view or pick,
the object is deleted immediately.
Parameter Descriptions
- object
- The object to dispose.
- function result
- Success or failure of the operation.
( TQ3Object ) Q3Object_Duplicate (
TQ3Object object
);
Discussion
Duplicates a Quesa object.
Returns a new copy of the object, with a reference count of 1.
Parameter Descriptions
- object
- The object to duplicate.
- function result
- A new copy of the object.
( TQ3Status ) Q3Object_EmptyElements (
TQ3Object object
);
Discussion
Empty an object of any elements it contains.
Same as Q3Shape_EmptyElements, except that the object is not
required to be a shape or set.
If the object is Shared, this operation will increment the object's edit index.
This function is not available in QD3D.
Parameter Descriptions
- object
- The object to update.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3Object_GetElement (
TQ3Object object,
TQ3ElementType theType,
void *data
);
Discussion
Get an element from an object.
Same as Q3Shape_GetElement, except that the object is not
required to be a shape or set.
This function is not available in QD3D.
Parameter Descriptions
- object
- The object to query.
- theType
- The type of the element data.
- data
- Receives the element data.
- function result
- Success or failure of the operation.
( TQ3ObjectType ) Q3Object_GetLeafType (
TQ3Object object
);
Discussion
Returns the leaf type of an object.
Returns the most specific type that can be identified from the object
(e.g., a camera object may have a leaf type of kQ3CameraTypeViewAngleAspect).
Returns kQ3ObjectTypeInvalid if the object type is unknown.
Parameter Descriptions
- object
- The object to test.
- function result
- The leaf type of the object.
( TQ3Status ) Q3Object_GetNextElementType (
TQ3Object object,
TQ3ElementType *theType
);
Discussion
Iterate through the element types in an object.
Same as Q3Shape_GetNextElementType, except that the object is not
required to be a shape or set.
Pass in kQ3ElementTypeNone to start iterating through the element
types in the object, and pass back the returned value to obtain
the next type. The type is set to kQ3ElementTypeNone if there are no more
elements in the shape.
This function is not available in QD3D.
Parameter Descriptions
- object
- The object to query.
- theType
- Receives the next element type.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3Object_GetProperty (
TQ3Object object,
TQ3ObjectType propType,
TQ3Uns32 bufferSize,
TQ3Uns32* actualSize,
void* buffer
);
Discussion
Get property data from an object.
The operation fails if the property does not exist or if you provide a
buffer that is not large enough to hold the data.
If you do not know the size of the property, you may call Q3Object_GetProperty
passing NULL for the buffer to find the size of the data, then allocate your
buffer and call Q3Object_GetProperty again.
This function is not available in QD3D.
Parameter Descriptions
- object
- The object.
- propType
- Property type tag.
- bufferSize
- Size of provided buffer in bytes.
- actualSize
- Returns size of returned data in bytes.
You may pass NULL if you do not need this information.
- buffer
- Buffer to receive the property data. May be NULL.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3Object_GetSet (
TQ3Object object,
TQ3SetObject* set
);
Discussion
Get the element set of an object. This is not the same as the set
returned by Q3Shape_GetSet.
This function is primarily for the use of file format plug-ins.
Most applications will not need it.
This function is not available in QD3D.
Parameter Descriptions
- object
- The object.
- set
- Receives a set object, or NULL.
- function result
- Success or failure of the operation.
( TQ3ObjectType ) Q3Object_GetType (
TQ3Object object
);
Discussion
Returns the top level type of an object.
Returns kQ3ObjectTypeElement, kQ3ObjectTypePick, kQ3ObjectTypeShared,
or kQ3ObjectTypeView. Returns kQ3ObjectTypeInvalid if the object type
is unknown.
Parameter Descriptions
- object
- The object to test.
- function result
- The top level type of the object.
( TQ3Boolean ) Q3Object_IsDrawable (
TQ3Object object
);
Discussion
Tests to see if an object is drawable.
Only drawable objects may be submitted to a view's rendering loop.
Parameter Descriptions
- object
- The object to test.
- function result
- True or false as the object is drawable or not.
( TQ3Boolean ) Q3Object_IsType (
TQ3Object object,
TQ3ObjectType theType
);
Discussion
Tests to see if an object belongs to a given type.
Examines both the object supplied and its parents. E.g., a camera object
would return true for a type of kQ3CameraTypeViewAngleAspect,
kQ3ShapeTypeCamera, kQ3SharedTypeShape, and kQ3ObjectTypeShared but would
return false for kQ3ObjectTypePick.
Parameter Descriptions
- object
- The object to test.
- theType
- The type to test the object against.
- function result
- True or false as the object belongs to the type or not.
( TQ3Boolean ) Q3Object_IsWritable (
TQ3Object object,
TQ3FileObject theFile
);
Discussion
Tests to see if an object is writable.
Only drawable objects may be submitted to a view's writing loop.
Parameter Descriptions
- object
- The object to test.
- function result
- True or false as the object is writable or not.
( TQ3Status ) Q3Object_RemoveProperty (
TQ3Object object,
TQ3ObjectType propType
);
Discussion
Remove a property from an object.
This function is not available in QD3D.
Parameter Descriptions
- object
- The object.
- propType
- Property type tag.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3Object_SetProperty (
TQ3Object object,
TQ3ObjectType propType,
TQ3Uns32 dataSize,
const void* data
);
Discussion
Set a property of an object. If there was already a property of the
same type, it is replaced.
Property type tags consisting of all lowercase ASCII letters are reserved
for Quesa internal use.
This function is not available in QD3D.
Parameter Descriptions
- object
- The object.
- propType
- Property type tag.
- dataSize
- Size in bytes of the data.
- data
- Data to copy into the property.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3Object_SetSet (
TQ3Object object,
TQ3SetObject set
);
Discussion
Assign to the element set of an object, disposing any previous set.
This is not the same as the set element that is
changed by Q3Shape_SetSet.
This function is primarily for the use of file format plug-ins.
Most applications will not need it.
This function is not available in QD3D.
Parameter Descriptions
- object
- The object.
- set
- A set object.
- function result
- A set object, or NULL.
( TQ3Status ) Q3Object_Submit (
TQ3Object object,
TQ3ViewObject view
);
Discussion
Submit an object to a view.
The object is submitted to the view's current processing loop,
e.g., for rendering, picking, or writing to a file.
Parameter Descriptions
- object
- The object to submit.
- view
- The view to submit the object to.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3Shape_AddElement (
TQ3ShapeObject shape,
TQ3ElementType theType,
const void *data
);
Discussion
Add an element to a shape.
Parameter Descriptions
- shape
- The object to update.
- theType
- The type of the element data.
- data
- The element data.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3Shape_ClearElement (
TQ3ShapeObject shape,
TQ3ElementType theType
);
Discussion
Empty a shape of a particular type of element.
Parameter Descriptions
- shape
- The object to update.
- theType
- The element type to remove.
- function result
- Success or failure of the operation.
( TQ3Boolean ) Q3Shape_ContainsElement (
TQ3ShapeObject shape,
TQ3ElementType theType
);
Discussion
Check to see if a shape contains an element of a given type.
Parameter Descriptions
- shape
- The object to query.
- theType
- The type of the element data to look for.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3Shape_EmptyElements (
TQ3ShapeObject shape
);
Discussion
Empty a shape of any elements it contains.
Parameter Descriptions
- shape
- The object to update.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3Shape_GetElement (
TQ3ShapeObject shape,
TQ3ElementType theType,
void *data
);
Discussion
Get an element from a shape.
Parameter Descriptions
- shape
- The object to query.
- theType
- The type of the element data.
- data
- Receives the element data.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3Shape_GetNextElementType (
TQ3ShapeObject shape,
TQ3ElementType *theType
);
Discussion
Iterate through the element types in a shape.
Pass in kQ3ElementTypeNone to start iterating through the element
types in the shape, and pass back the returned value to obtain
the next type. Is set to kQ3ElementTypeNone if there are no more
elements in the shape.
Parameter Descriptions
- shape
- The object to query.
- theType
- Receives the next element type.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3Shape_GetSet (
TQ3ShapeObject shape,
TQ3SetObject *theSet
);
Discussion
Get the set element currently associated with a shape.
The function call Q3Shape_GetSet( o, &s ) is equivalent to
Q3Shape_GetElement( o, kQ3ElementTypeSet, &s ).
Note that this is not the same as the attribute set of a geometry object,
nor is in the internal set which holds elements on an object. That is,
after adding elements or attributes to an object, this function may still
return the NULL set.
Parameter Descriptions
- shape
- The object to query.
- theSet
- Receives the set of the object, or NULL.
- function result
- Success or failure of the operation.
( TQ3ObjectType ) Q3Shape_GetType (
TQ3ShapeObject shape
);
Discussion
Get the type of a shape object.
Returns kQ3ObjectTypeInvalid if the object is not a shape object or
the type can not be determined. Returns a kQ3ShapeTypeXXXX value
for shape objects.
Parameter Descriptions
- shape
- The object to test.
- function result
- The type of the shape object.
( TQ3Status ) Q3Shape_SetSet (
TQ3ShapeObject shape,
TQ3SetObject theSet
);
Discussion
Set the set element currently associated with a shape.
The function call Q3Shape_SetSet( o, s ) is equivalent to
Q3Shape_SetElement( o, kQ3ElementTypeSet, &s ).
Note that this is not the same as the attribute set of a geometry object.
Parameter Descriptions
- shape
- The object to update.
- theSet
- The new set for the object.
- function result
- Success or failure of the operation.
( TQ3Status ) Q3Shared_Edited (
TQ3SharedObject sharedObject
);
Discussion
Change the edit index of a shared object.
Editing a shared object will change its edit index automatically: this
function is typically used for shared plug-in objects who need to indicate
to Quesa that their private data has changed.
Parameter Descriptions
- sharedObject
- The object to update.
- function result
- Success or failure of the operation.
( TQ3Uns32 ) Q3Shared_GetEditIndex (
TQ3SharedObject sharedObject
);
Discussion
Get the edit index of a shared object.
An edit index is a unique number associated with a shared object, which
changes each time the object is edited. By testing this number, you
can determine when an object has been edited.
Parameter Descriptions
- sharedObject
- The object to query.
- function result
- The current edit index of the object.
( TQ3SharedObject ) Q3Shared_GetReference (
TQ3SharedObject sharedObject
);
Discussion
Increment the reference count of a shared object.
Parameter Descriptions
- sharedObject
- The object whose reference count should be incremented.
- function result
- The object whose reference count has been incremented.
( TQ3Uns32 ) Q3Shared_GetReferenceCount (
TQ3SharedObject sharedObject
);
Discussion
Return the reference count of a shared object.
This function should be used only for debugging. If you are
tempted to use it for something else, then you probably don't
understand the correct way to work with reference-counted objects.
This function is not available in QD3D.
Parameter Descriptions
- sharedObject
- The object to test.
- function result
- Reference count.
( TQ3ObjectType ) Q3Shared_GetType (
TQ3SharedObject sharedObject
);
Discussion
Get the type of a shared object.
Returns kQ3ObjectTypeInvalid if the object is not a shared object or
the type can not be determined. Returns a kQ3SharedTypeXXXX value
for shared objects.
Parameter Descriptions
- sharedObject
- The object to test.
- function result
- The type of the shared object.
( TQ3Boolean ) Q3Shared_IsReferenced (
TQ3SharedObject sharedObject
);
Discussion
Determine if a shared object has more than one reference to it.
Returns kQ3True if the object has more than one reference to it. Will
return kQ3False if the object a reference count of one.
Parameter Descriptions
- sharedObject
- The object to test.
- function result
- True or false as the object has more than one reference.
Set the edit index of a shared object.
( void ) Q3Shared_SetEditIndex (
TQ3SharedObject inObject,
TQ3Uns32 inEditIndex
);
Discussion
This function should be used even more rarely than
Q3Shared_Edited. It was added to solve a specific problem:
Caching information in a custom element attached to an object
without changing the edit index of the object.
This function is not available in QD3D.
Parameter Descriptions
- inObject
- A shared object to update.
- inEditIndex
- New edit index.
Typedefs
Type identifier for an element.
typedef TQ3Int32 TQ3ElementType;
End cap flag word, see TQ3EndCapMasks for specific values.
typedef TQ3Uns32 TQ3EndCap;
32-bit floating-point number.
typedef float TQ3Float32;
64-bit floating-point number.
typedef double TQ3Float64;
Group position opaque pointer.
typedef struct OpaqueTQ3GroupPosition *TQ3GroupPosition;
Signed 16-bit integer.
typedef int16_t TQ3Int16;
Signed 32-bit integer.
typedef int32_t TQ3Int32;
Signed 64-bit integer.
typedef struct TQ3Int64 {
TQ3Int32 hi;
TQ3Uns32 lo;
} TQ3Int64;
Signed 8-bit integer.
typedef int8_t TQ3Int8;
Quesa object opaque pointer.
typedef struct OpaqueTQ3Object *TQ3Object;
Class name C string.
typedef char TQ3ObjectClassNameString[kQ3StringMaximumLength];
Numeric type code for a class of Quesa objects.
typedef TQ3Int32 TQ3ObjectType;
Size type.
typedef TQ3Uns32 TQ3Size;
Unsigned 16-bit integer.
typedef uint16_t TQ3Uns16;
Unsigned 32-bit integer.
typedef uint32_t TQ3Uns32;
Unsigned 64-bit integer.
typedef struct TQ3Uns64 {
TQ3Uns32 hi;
TQ3Uns32 lo;
} TQ3Uns64;
Unsigned 8-bit integer.
typedef uint8_t TQ3Uns8;
Type identifier for an element.
typedef TQ3Uns32 TQ3XMethodType;
Object class opaque pointer.
typedef struct OpaqueTQ3XObjectClass *TQ3XObjectClass;
Structs
typedef struct TQ3Area {
TQ3Point2D min;
TQ3Point2D max;
} TQ3Area;
Discussion
Fundamental area type.
Field Descriptions
- min
- Minimum corner of area.
- max
- Maximum corner of area.
typedef struct TQ3Bitmap {
TQ3Uns8 *image;
TQ3Uns32 width;
TQ3Uns32 height;
TQ3Uns32 rowBytes;
TQ3Endian bitOrder;
} TQ3Bitmap;
Discussion
Fundamental Bitmap type.
Field Descriptions
- image
- Pointer to (height*rowBytes) sized block of memory containing the image data.
Each row of image data starts on a new byte.
- width
- Width of the image.
- height
- Height of the image.
- rowBytes
- Distance in bytes from begining of one row of image data to the next.
- bitOrder
- The order in which bits in a byte are addressed within the image data.
typedef struct TQ3BoundingBox {
TQ3Point3D min;
TQ3Point3D max;
TQ3Boolean isEmpty;
} TQ3BoundingBox;
Discussion
Fundamental bounding box type.
Field Descriptions
- min
- Minimum corner of bounding box.
- max
- Maximum corner of bounding box.
- isEmpty
- Is the bounding box empty. The box is only valid if isEmpty is kQ3False.
typedef struct TQ3BoundingSphere {
TQ3Point3D origin;
float radius;
TQ3Boolean isEmpty;
} TQ3BoundingSphere;
Discussion
Fundamental bounding sphere type.
Field Descriptions
- origin
- Origin of bounding sphere.
- radius
- Radius of bounding sphere.
- isEmpty
- Is the bounding sphere empty? The sphere is only valid if isEmpty is kQ3False.
typedef struct TQ3ColorARGB {
float a;
float r;
float g;
float b;
} TQ3ColorARGB;
Discussion
Fundamental ARGB point type.
Field Descriptions
- a
- Alpha component, between 0.0 (transparent) and 1.0 (opaque).
- r
- Red component, between 0.0 and 1.0.
- g
- Green component, between 0.0 and 1.0.
- b
- Blue component, between 0.0 and 1.0.
typedef struct TQ3ColorRGB {
float r;
float g;
float b;
} TQ3ColorRGB;
Discussion
Fundamental RGB colour type.
Field Descriptions
- r
- Red component, between 0.0 and 1.0.
- g
- Green component, between 0.0 and 1.0.
- b
- Blue component, between 0.0 and 1.0.
typedef struct TQ3ColorRGBA {
float r;
float g;
float b;
float a;
} TQ3ColorRGBA;
Discussion
Fundamental RGBA point type.
Field Descriptions
- r
- Red component, between 0.0 and 1.0.
- g
- Green component, between 0.0 and 1.0.
- b
- Blue component, between 0.0 and 1.0.
- a
- Alpha component, between 0.0 (transparent) and 1.0 (opaque).
typedef struct TQ3CompressedPixmap {
TQ3StorageObject compressedImage;
TQ3Endian imageDescByteOrder;
TQ3StorageObject imageDesc;
TQ3Boolean makeMipmaps;
TQ3Uns32 width;
TQ3Uns32 height;
TQ3Uns32 pixelSize;
TQ3PixelType pixelType;
} TQ3CompressedPixmap;
Discussion
QuickTime compressed Pixmap image type. Only available on platforms with QuickTime.
Field Descriptions
- compressedImage
- A storage object that contains the QuickTime compressed image data.
- imageDescByteOrder
- Endianness of data in the imageDesc field.
- imageDesc
- QuickTime image description.
- makeMipmaps
- Indicates if mipmapping is required.
- width
- Width of the image.
- height
- Height of the image.
- pixelSize
- Size in bits of each pixel (must be 16 or 32).
- pixelType
- The pixel format of the image data. The format must be appropriate for pixelSize.
typedef struct TQ3Matrix3x3 {
float value[3][3];
} TQ3Matrix3x3;
Discussion
Fundamental 3x3 matrix type.
Field Descriptions
- value
- 3x3 array of values that define the matrix.
typedef struct TQ3Matrix4x4 {
float value[4][4];
} TQ3Matrix4x4;
Discussion
Fundamental 4x4 matrix type.
Field Descriptions
- value
- 4x4 array of values that define the matrix.
typedef struct TQ3Mipmap {
TQ3StorageObject image;
TQ3Boolean useMipmapping;
TQ3PixelType pixelType;
TQ3Endian bitOrder;
TQ3Endian byteOrder;
TQ3Uns32 reserved;
TQ3MipmapImage mipmaps[32];
} TQ3Mipmap;
Discussion
This is the data structure for a mipmap texture. If the useMipmapping field is kQ3False,
then only the first record of the mipmaps array needs to be filled in. If useMipmapping
is kQ3True, then the number of mipmaps should be the base 2 logarithm of the larger
dimension of the first mipmap, plus 1. For example, if the first mipmap is of size 4 × 16, then
you must also include mipmaps of sizes 2 × 8, 1 × 4, 1 × 2, and 1 × 1,
making 5 mipmaps in all.
Field Descriptions
- image
- A storage object that contains the image data.
- useMipmapping
- Flag indicating if mipmapping should be used and all mipmaps have been supplied.
- pixelType
- The pixel format of the image data.
- bitOrder
- The order in which bits in a byte are addressed within the image data.
- byteOrder
- The order in which bytes in a word are addressed within the image data.
- reserved
- Reserved - must be set to 0.
- mipmaps
- Up to 32 mip-map image specifications.
typedef struct TQ3MipmapImage {
TQ3Uns32 width;
TQ3Uns32 height;
TQ3Uns32 rowBytes;
TQ3Uns32 offset;
} TQ3MipmapImage;
Discussion
Fundamental Mipmap image type.
Field Descriptions
- width
- Width of the mipmap, which must be a power of 2.
- height
- Height of the mipmap, which must be a power of 2.
- rowBytes
- Distance in bytes from begining of one row of image data to the next.
- offset
- Offset in bytes from the begining of the image base to this mipmap.
typedef struct TQ3Param2D {
float u;
float v;
} TQ3Param2D;
Discussion
Fundamental 2D parametric point type.
Field Descriptions
- u
- u component.
- v
- v component.
typedef struct TQ3Param3D {
float u;
float v;
float w;
} TQ3Param3D;
Discussion
Fundamental 3D parametric point type.
Field Descriptions
- u
- u component.
- v
- v component.
- w
- w component.
typedef struct TQ3Pixmap {
void *image;
TQ3Uns32 width;
TQ3Uns32 height;
TQ3Uns32 rowBytes;
TQ3Uns32 pixelSize;
TQ3PixelType pixelType;
TQ3Endian bitOrder;
TQ3Endian byteOrder;
} TQ3Pixmap;
Discussion
Fundamental Pixmap type.
Field Descriptions
- image
- Pointer to (height*rowBytes) sized block of memory containing the image data.
- width
- Width of the image.
- height
- Height of the image.
- rowBytes
- Distance in bytes from begining of one row of image data to the next.
- pixelSize
- Size in bits of each pixel.
- pixelType
- The pixel format of the image data. The format must be appropriate for pixelSize.
- bitOrder
- The order in which bits in a byte are addressed within the image data.
- byteOrder
- The order in which bytes in a word are addressed within the image data.
typedef struct TQ3PlaneEquation {
TQ3Vector3D normal;
float constant;
} TQ3PlaneEquation;
Discussion
Fundamental plane equation type.
Field Descriptions
- normal
- The normal vector to the plane.
- constant
- The plane constant (the value d in the plane equation ax+by+cz+d=0).
typedef struct TQ3Point2D {
float x;
float y;
} TQ3Point2D;
Discussion
Fundamental 2D point type.
Field Descriptions
- x
- x coordinate.
- y
- y coordinate.
typedef struct TQ3Point3D {
float x;
float y;
float z;
} TQ3Point3D;
Discussion
Fundamental 3D point type.
Field Descriptions
- x
- x coordinate.
- y
- y coordinate.
- z
- z coordinate.
typedef struct TQ3PolarPoint {
float r;
float theta;
} TQ3PolarPoint;
Discussion
Fundamental polar point type.
Field Descriptions
- r
- Distance along the radius vector from polar origin.
- theta
- Angle in radians between polar axis and the radius vector.
typedef struct TQ3Quaternion {
float w;
float x;
float y;
float z;
} TQ3Quaternion;
Discussion
Fundamental Quaternion type.
Field Descriptions
- w
- w component.
- x
- x component.
- y
- y component.
- z
- z component.
typedef struct TQ3RationalPoint3D {
float x;
float y;
float w;
} TQ3RationalPoint3D;
Discussion
Fundamental 3D rational point type.
Field Descriptions
- x
- x coordinate.
- y
- y coordinate.
- w
- Point weight.
typedef struct TQ3RationalPoint4D {
float x;
float y;
float z;
float w;
} TQ3RationalPoint4D;
Discussion
Fundamental 4D rational point type.
Field Descriptions
- x
- x coordinate.
- y
- y coordinate.
- z
- z coordinate.
- w
- Point weight.
typedef struct TQ3Ray3D {
TQ3Point3D origin;
TQ3Vector3D direction;
} TQ3Ray3D;
Discussion
Fundamental ray type.
Field Descriptions
- origin
- Origin of ray.
- direction
- Direction of ray.
typedef struct TQ3Sphere {
TQ3Point3D origin;
float radius;
} TQ3Sphere;
Discussion
Fundamental sphere type.
Field Descriptions
- origin
- Origin of sphere.
- radius
- Radius of sphere.
typedef struct TQ3SphericalPoint {
float rho;
float theta;
float phi;
} TQ3SphericalPoint;
Discussion
Fundamental spherical point type.
Field Descriptions
- rho
- Distance along the radius vector from polar origin.
- theta
- Angle in radians between x axis and the projection of the
radius vector onto the xy plane.
- phi
- Angle in radians between z axis and the radius vector.
typedef struct TQ3StoragePixmap {
TQ3StorageObject image;
TQ3Uns32 width;
TQ3Uns32 height;
TQ3Uns32 rowBytes;
TQ3Uns32 pixelSize;
TQ3PixelType pixelType;
TQ3Endian bitOrder;
TQ3Endian byteOrder;
} TQ3StoragePixmap;
Discussion
Fundamental storage Pixmap type.
Field Descriptions
- image
- A storage object that contains the image data.
- width
- Width of the image.
- height
- Height of the image.
- rowBytes
- Distance in bytes from begining of one row of image data to the next.
- pixelSize
- Size in bits of each pixel.
- pixelType
- The pixel format of the image data. The format must be appropriate for pixelSize.
- bitOrder
- The order in which bits in a byte are addressed within the image data.
- byteOrder
- The order in which bytes in a word are addressed within the image data.
typedef struct TQ3SubClassData {
TQ3Uns32 numClasses;
TQ3ObjectType *classTypes;
} TQ3SubClassData;
Discussion
Object sub-class type.
Field Descriptions
- numClasses
- The number of types contained in classTypes.
- classTypes
- The types of the sub-classes.
typedef struct TQ3Tangent2D {
TQ3Vector3D uTangent;
TQ3Vector3D vTangent;
} TQ3Tangent2D;
Discussion
Fundamental 2D parametric surface tangent type.
Field Descriptions
- uTangent
- Tangent in the u direction.
- vTangent
- Tangent in the v direction.
typedef struct TQ3Tangent3D {
TQ3Vector3D uTangent;
TQ3Vector3D vTangent;
TQ3Vector3D wTangent;
} TQ3Tangent3D;
Discussion
Fundamental 3D parametric surface tangent type.
Field Descriptions
- uTangent
- Tangent in the u direction.
- vTangent
- Tangent in the v direction.
- wTangent
- Tangent in the w direction.
typedef struct TQ3Vector2D {
float x;
float y;
} TQ3Vector2D;
Discussion
Fundamental 2D vector type.
Field Descriptions
- x
- x coordinate.
- y
- y coordinate.
typedef struct TQ3Vector3D {
float x;
float y;
float z;
} TQ3Vector3D;
Discussion
Fundamental 3D vector type.
Field Descriptions
- x
- x coordinate.
- y
- y coordinate.
- z
- z coordinate.
typedef struct TQ3Vertex3D {
TQ3Point3D point;
TQ3AttributeSet attributeSet;
} TQ3Vertex3D;
Discussion
Fundamental vertex type.
Field Descriptions
- point
- Location of the vertex.
- attributeSet
- Attribute set for the vertex.
Enumerations
enum {
kQ3StringMaximumLength = 1024,
kQ3ArrayIndexNULL = 0xFFFFFFFFUL
};
Discussion
constants
Constants
- kQ3StringMaximumLength
- Maximum length of TQ3ObjectClassNameString.
- kQ3ArrayIndexNULL
- NULL array index.
Type codes of Quesa object classes.
enum {
kQ3ObjectTypeInvalid = ((TQ3ObjectType) 0),
kQ3ObjectTypeView = Q3_OBJECT_TYPE('v', 'i', 'e', 'w'),
kQ3ObjectTypeViewer = Q3_OBJECT_TYPE('v', 'w', 'e', 'r'),
kQ3ObjectTypeSlab = Q3_OBJECT_TYPE('s', 'l', 'a', 'b'),
kQ3ObjectTypeElement = Q3_OBJECT_TYPE('e', 'l', 'm', 'n'),
kQ3ElementTypeAttribute = Q3_OBJECT_TYPE('e', 'a', 't', 't'),
kQ3ObjectTypePick = Q3_OBJECT_TYPE('p', 'i', 'c', 'k'),
kQ3PickTypeWindowPoint = Q3_OBJECT_TYPE('p', 'k', 'w', 'p'),
kQ3PickTypeWindowRect = Q3_OBJECT_TYPE('p', 'k', 'w', 'r'),
kQ3PickTypeWorldRay = Q3_OBJECT_TYPE('p', 'k', 'r', 'y'),
kQ3ObjectTypeShared = Q3_OBJECT_TYPE('s', 'h', 'r', 'd'),
kQ3SharedTypeRenderer = Q3_OBJECT_TYPE('r', 'd', 'd', 'r'),
kQ3RendererTypeWireFrame = Q3_OBJECT_TYPE('w', 'r', 'f', 'r'),
kQ3RendererTypeGeneric = Q3_OBJECT_TYPE('g', 'n', 'r', 'r'),
kQ3RendererTypeInteractive = Q3_OBJECT_TYPE('c', 't', 'w', 'n'),
kQ3RendererTypeOpenGL = Q3_OBJECT_TYPE('o', 'g', 'l', 'r'),
kQ3RendererTypeCartoon = Q3_OBJECT_TYPE('t', 'o', 'o', 'n'),
kQ3RendererTypeHiddenLine = Q3_OBJECT_TYPE('h', 'd', 'n', 'l'),
kQ3SharedTypeShape = Q3_OBJECT_TYPE('s', 'h', 'a', 'p'),
kQ3ShapeTypeGeometry = Q3_OBJECT_TYPE('g', 'm', 't', 'r'),
kQ3GeometryTypeBox = Q3_OBJECT_TYPE('b', 'o', 'x', ' '),
kQ3GeometryTypeGeneralPolygon = Q3_OBJECT_TYPE('g', 'p', 'g', 'n'),
kQ3GeometryTypeLine = Q3_OBJECT_TYPE('l', 'i', 'n', 'e'),
kQ3GeometryTypeMarker = Q3_OBJECT_TYPE('m', 'r', 'k', 'r'),
kQ3GeometryTypePixmapMarker = Q3_OBJECT_TYPE('m', 'r', 'k', 'p'),
kQ3GeometryTypeMesh = Q3_OBJECT_TYPE('m', 'e', 's', 'h'),
kQ3GeometryTypeNURBCurve = Q3_OBJECT_TYPE('n', 'r', 'b', 'c'),
kQ3GeometryTypeNURBPatch = Q3_OBJECT_TYPE('n', 'r', 'b', 'p'),
kQ3GeometryTypePoint = Q3_OBJECT_TYPE('p', 'n', 't', ' '),
kQ3GeometryTypePolygon = Q3_OBJECT_TYPE('p', 'l', 'y', 'g'),
kQ3GeometryTypePolyLine = Q3_OBJECT_TYPE('p', 'l', 'y', 'l'),
kQ3GeometryTypeTriangle = Q3_OBJECT_TYPE('t', 'r', 'n', 'g'),
kQ3GeometryTypeTriGrid = Q3_OBJECT_TYPE('t', 'r', 'i', 'g'),
kQ3GeometryTypeCone = Q3_OBJECT_TYPE('c', 'o', 'n', 'e'),
kQ3GeometryTypeCylinder = Q3_OBJECT_TYPE('c', 'y', 'l', 'n'),
kQ3GeometryTypeDisk = Q3_OBJECT_TYPE('d', 'i', 's', 'k'),
kQ3GeometryTypeEllipse = Q3_OBJECT_TYPE('e', 'l', 'p', 's'),
kQ3GeometryTypeEllipsoid = Q3_OBJECT_TYPE('e', 'l', 'p', 'd'),
kQ3GeometryTypePolyhedron = Q3_OBJECT_TYPE('p', 'l', 'h', 'd'),
kQ3GeometryTypeTorus = Q3_OBJECT_TYPE('t', 'o', 'r', 's'),
kQ3GeometryTypeTriMesh = Q3_OBJECT_TYPE('t', 'm', 's', 'h'),
kQ3ShapeTypeShader = Q3_OBJECT_TYPE('s', 'h', 'd', 'r'),
kQ3ShaderTypeSurface = Q3_OBJECT_TYPE('s', 'u', 's', 'h'),
kQ3SurfaceShaderTypeTexture = Q3_OBJECT_TYPE('t', 'x', 's', 'u'),
kQ3ShaderTypeIllumination = Q3_OBJECT_TYPE('i', 'l', 's', 'h'),
kQ3IlluminationTypePhong = Q3_OBJECT_TYPE('p', 'h', 'i', 'l'),
kQ3IlluminationTypeLambert = Q3_OBJECT_TYPE('l', 'm', 'i', 'l'),
kQ3IlluminationTypeNULL = Q3_OBJECT_TYPE('n', 'u', 'i', 'l'),
kQ3ShapeTypeStyle = Q3_OBJECT_TYPE('s', 't', 'y', 'l'),
kQ3StyleTypeBackfacing = Q3_OBJECT_TYPE('b', 'c', 'k', 'f'),
kQ3StyleTypeInterpolation = Q3_OBJECT_TYPE('i', 'n', 't', 'p'),
kQ3StyleTypeFill = Q3_OBJECT_TYPE('f', 'i', 's', 't'),
kQ3StyleTypePickID = Q3_OBJECT_TYPE('p', 'k', 'i', 'd'),
kQ3StyleTypeCastShadows = Q3_OBJECT_TYPE('c', 'a', 's', 'h'),
kQ3StyleTypeLineWidth = Q3_OBJECT_TYPE('l', 'n', 'w', 'd'),
#endif // QUESA_ALLOW_QD3D_EXTENSIONS
kQ3StyleTypeReceiveShadows = Q3_OBJECT_TYPE('r', 'c', 's', 'h'),
kQ3StyleTypeHighlight = Q3_OBJECT_TYPE('h', 'i', 'g', 'h'),
kQ3StyleTypeSubdivision = Q3_OBJECT_TYPE('s', 'b', 'd', 'v'),
kQ3StyleTypeOrientation = Q3_OBJECT_TYPE('o', 'f', 'd', 'r'),
kQ3StyleTypePickParts = Q3_OBJECT_TYPE('p', 'k', 'p', 't'),
kQ3StyleTypeAntiAlias = Q3_OBJECT_TYPE('a', 'n', 't', 'i'),
kQ3StyleTypeFog = Q3_OBJECT_TYPE('f', 'o', 'g', 'g'),
kQ3ShapeTypeTransform = Q3_OBJECT_TYPE('x', 'f', 'r', 'm'),
kQ3TransformTypeMatrix = Q3_OBJECT_TYPE('m', 't', 'r', 'x'),
kQ3TransformTypeScale = Q3_OBJECT_TYPE('s', 'c', 'a', 'l'),
kQ3TransformTypeTranslate = Q3_OBJECT_TYPE('t', 'r', 'n', 's'),
kQ3TransformTypeRotate = Q3_OBJECT_TYPE('r', 'o', 't', 't'),
kQ3TransformTypeRotateAboutPoint= Q3_OBJECT_TYPE('r', 't', 'a', 'p'),
kQ3TransformTypeRotateAboutAxis = Q3_OBJECT_TYPE('r', 't', 'a', 'a'),
kQ3TransformTypeQuaternion = Q3_OBJECT_TYPE('q', 't', 'r', 'n'),
kQ3TransformTypeReset = Q3_OBJECT_TYPE('r', 's', 'e', 't'),
kQ3TransformTypeCamera = Q3_OBJECT_TYPE('c', 'a', 'm', 't'),
kQ3TransformTypeCameraRasterize = Q3_OBJECT_TYPE('r', 'a', 's', 't'),
#endif // QUESA_ALLOW_QD3D_EXTENSIONS
kQ3ShapeTypeLight = Q3_OBJECT_TYPE('l', 'g', 'h', 't'),
kQ3LightTypeAmbient = Q3_OBJECT_TYPE('a', 'm', 'b', 'n'),
kQ3LightTypeDirectional = Q3_OBJECT_TYPE('d', 'r', 'c', 't'),
kQ3LightTypePoint = Q3_OBJECT_TYPE('p', 'n', 't', 'l'),
kQ3LightTypeSpot = Q3_OBJECT_TYPE('s', 'p', 'o', 't'),
kQ3ShapeTypeCamera = Q3_OBJECT_TYPE('c', 'm', 'r', 'a'),
kQ3CameraTypeOrthographic = Q3_OBJECT_TYPE('o', 'r', 't', 'h'),
kQ3CameraTypeViewPlane = Q3_OBJECT_TYPE('v', 'w', 'p', 'l'),
kQ3CameraTypeViewAngleAspect = Q3_OBJECT_TYPE('v', 'a', 'n', 'a'),
kQ3ShapeTypeStateOperator = Q3_OBJECT_TYPE('s', 't', 'o', 'p'),
kQ3StateOperatorTypePush = Q3_OBJECT_TYPE('p', 'u', 's', 'h'),
kQ3StateOperatorTypePop = Q3_OBJECT_TYPE('p', 'o', 'p', ' '),
kQ3ShapeTypeGroup = Q3_OBJECT_TYPE('g', 'r', 'u', 'p'),
kQ3GroupTypeDisplay = Q3_OBJECT_TYPE('d', 's', 'p', 'g'),
kQ3DisplayGroupTypeOrdered = Q3_OBJECT_TYPE('o', 'r', 'd', 'g'),
kQ3DisplayGroupTypeIOProxy = Q3_OBJECT_TYPE('i', 'o', 'p', 'x'),
kQ3GroupTypeLight = Q3_OBJECT_TYPE('l', 'g', 'h', 'g'),
kQ3GroupTypeInfo = Q3_OBJECT_TYPE('i', 'n', 'f', 'o'),
kQ3ShapeTypeUnknown = Q3_OBJECT_TYPE('u', 'n', 'k', 'n'),
kQ3UnknownTypeText = Q3_OBJECT_TYPE('u', 'k', 't', 'x'),
kQ3UnknownTypeBinary = Q3_OBJECT_TYPE('u', 'k', 'b', 'n'),
kQ3ShapeTypeReference = Q3_OBJECT_TYPE('r', 'f', 'r', 'n'),
kQ3ReferenceTypeExternal = Q3_OBJECT_TYPE('r', 'f', 'e', 'x'),
kQ3SharedTypeSet = Q3_OBJECT_TYPE('s', 'e', 't', ' '),
kQ3SetTypeAttribute = Q3_OBJECT_TYPE('a', 't', 't', 'r'),
kQ3SharedTypeDrawContext = Q3_OBJECT_TYPE('d', 'c', 't', 'x'),
kQ3DrawContextTypePixmap = Q3_OBJECT_TYPE('d', 'p', 'x', 'p'),
kQ3DrawContextTypeMacintosh = Q3_OBJECT_TYPE('d', 'm', 'a', 'c'),
kQ3DrawContextTypeCocoa = Q3_OBJECT_TYPE('d', 'c', 'c', 'o'),
kQ3DrawContextTypeWin32DC = Q3_OBJECT_TYPE('d', 'w', '3', '2'),
kQ3DrawContextTypeDDSurface = Q3_OBJECT_TYPE('d', 'd', 'd', 's'),
kQ3DrawContextTypeX11 = Q3_OBJECT_TYPE('d', 'x', '1', '1'),
kQ3SharedTypeTexture = Q3_OBJECT_TYPE('t', 'x', 't', 'r'),
kQ3TextureTypePixmap = Q3_OBJECT_TYPE('t', 'x', 'p', 'm'),
kQ3TextureTypeMipmap = Q3_OBJECT_TYPE('t', 'x', 'm', 'm'),
kQ3TextureTypeCompressedPixmap = Q3_OBJECT_TYPE('t', 'x', 'c', 'p'),
kQ3SharedTypeFile = Q3_OBJECT_TYPE('f', 'i', 'l', 'e'),
kQ3SharedTypeStorage = Q3_OBJECT_TYPE('s', 't', 'r', 'g'),
kQ3StorageTypeMemory = Q3_OBJECT_TYPE('m', 'e', 'm', 's'),
kQ3MemoryStorageTypeHandle = Q3_OBJECT_TYPE('h', 'n', 'd', 'l'),
kQ3StorageTypePath = Q3_OBJECT_TYPE('Q', 's', 't', 'p'),
kQ3StorageTypeUnix = Q3_OBJECT_TYPE('u', 'x', 's', 't'),
kQ3UnixStorageTypePath = Q3_OBJECT_TYPE('u', 'n', 'i', 'x'),
kQ3StorageTypeMacintosh = Q3_OBJECT_TYPE('m', 'a', 'c', 'n'),
kQ3MacintoshStorageTypeFSSpec = Q3_OBJECT_TYPE('m', 'a', 'c', 'p'),
kQ3StorageTypeWin32 = Q3_OBJECT_TYPE('w', 'i', 's', 't'),
kQ3SharedTypeString = Q3_OBJECT_TYPE('s', 't', 'r', 'n'),
kQ3StringTypeCString = Q3_OBJECT_TYPE('s', 't', 'r', 'c'),
kQ3SharedTypeShapePart = Q3_OBJECT_TYPE('s', 'p', 'r', 't'),
kQ3ShapePartTypeMeshPart = Q3_OBJECT_TYPE('s', 'p', 'm', 'h'),
kQ3MeshPartTypeMeshFacePart = Q3_OBJECT_TYPE('m', 'f', 'a', 'c'),
kQ3MeshPartTypeMeshEdgePart = Q3_OBJECT_TYPE('m', 'e', 'd', 'g'),
kQ3MeshPartTypeMeshVertexPart = Q3_OBJECT_TYPE('m', 'v', 't', 'x'),
kQ3SharedTypeControllerState = Q3_OBJECT_TYPE('c', 't', 's', 't'),
kQ3SharedTypeTracker = Q3_OBJECT_TYPE('t', 'r', 'k', 'r'),
kQ3SharedTypeViewHints = Q3_OBJECT_TYPE('v', 'w', 'h', 'n'),
kQ3SharedTypeEndGroup = Q3_OBJECT_TYPE('e', 'n', 'd', 'g')
};
Discussion
These values should be considered to be of type TQ3ObjectType.
typedef enum {
kQ3AxisX = 0,
kQ3AxisY = 1,
kQ3AxisZ = 2,
kQ3AxisSize32 = 0xFFFFFFFF
} TQ3Axis;
Discussion
Fundamental axis type.
Constants
- kQ3AxisX
- Indicates X axis.
- kQ3AxisY
- Indicates Y axis.
- kQ3AxisZ
- Indicates Z axis.
typedef enum {
kQ3False = 0,
kQ3True = 1,
kQ3BooleanSize32 = 0xFFFFFFFF
} TQ3Boolean;
Discussion
Fundamental boolean type.
Constants
- kQ3False
- False.
- kQ3True
- True.
typedef enum {
kQ3ComputeBoundsExact = 0,
kQ3ComputeBoundsApproximate = 1,
kQ3ComputeBoundsSize32 = 0xFFFFFFFF
} TQ3ComputeBounds;
Discussion
Bounds accuracy types.
Constants
- kQ3ComputeBoundsExact
- Compute exact bounds by transforming vertices
to world coordinates then calculating bounds.
Slower, but more accurate.
- kQ3ComputeBoundsApproximate
- Compute approximate bounds by transforming
local bounding box to world coordinates.
Faster, but less accurate.
typedef enum {
kQ3ElementTypeNone = 0,
kQ3ElementTypeUnknown = 32,
kQ3ElementTypeSet = 33,
kQ3ElementTypeSize32 = 0xFFFFFFFF
} TQ3ElementTypes;
Discussion
Fundamental element types.
Constants
- kQ3ElementTypeNone
- Indicates no element.
- kQ3ElementTypeUnknown
- Indicates unknown element type.
- kQ3ElementTypeSet
- Indicates set element.
typedef enum {
kQ3EndCapNone = 0,
kQ3EndCapMaskTop = (1 << 0),
kQ3EndCapMaskBottom = (1 << 1),
kQ3EndCapMaskInterior = (1 << 2),
kQ3EndCapSize32 = 0xFFFFFFFF
} TQ3EndCapMasks;
Discussion
Fundamental end caps type.
Constants
- kQ3EndCapNone
- No end caps.
- kQ3EndCapMaskTop
- Top end cap.
- kQ3EndCapMaskBottom
- Bottom end cap.
- kQ3EndCapMaskInterior
- Interior end cap.
typedef enum {
kQ3EndianBig = 0,
kQ3EndianLittle = 1,
kQ3EndianSize32 = 0xFFFFFFFF
} TQ3Endian;
Discussion
Fundamental endian type.
Constants
- kQ3EndianBig
- Big endian.
- kQ3EndianLittle
- Little endian.
typedef enum {
kQ3LanguageDefault = 0,
kQ3LanguageEnglishUS = 1,
kQ3LanguageSize32 = 0xFFFFFFFF
} TQ3Language;
Discussion
Languages.
Constants
- kQ3LanguageDefault
- Default language for current OS.
- kQ3LanguageEnglishUS
- US English.
Fundamental pixel formats used in pixmaps and mipmaps.
typedef enum {
kQ3PixelTypeRGB32 = 0,
kQ3PixelTypeARGB32 = 1,
kQ3PixelTypeRGB16 = 2,
kQ3PixelTypeARGB16 = 3,
kQ3PixelTypeRGB16_565 = 4,
kQ3PixelTypeRGB24 = 5,
kQ3PixelTypeUnknown = 200,
kQ3PixelTypeSize32 = 0xFFFFFFFF
} TQ3PixelType;
Discussion
The layout of the pixel bits in memory depend on the byte order as well
as the pixel format. For example, kQ3PixelTypeARGB32 with
kQ3EndianLittle means you have blue, then green, then red, then alpha.
When dealing with formats that have an alpha channel, you must be aware
of whether your data has premultiplied alpha or not. By default,
Quesa's built-in OpenGL-based renderers assume that alpha is
premultiplied. However, you can attach an object property of type
kQ3RendererPropertyConvertToPremultipliedAlpha to the renderer object
to tell Quesa to convert non-premultiplied alpha to premultiplied alpha.
Constants
- kQ3PixelTypeRGB32
- 8 bits for red, green, and blue. High-order byte ignored.
- kQ3PixelTypeARGB32
- 8 bits for alpha, red, green, and blue.
- kQ3PixelTypeRGB16
- 5 bits for red, green, and blue. High-order bit ignored.
- kQ3PixelTypeARGB16
- 1 bit for alpha. 5 bits for red, green, and blue.
- kQ3PixelTypeRGB16_565
- 5 bits for red, 6 bits for green, 5 bits for blue.
- kQ3PixelTypeRGB24
- 8 bits for red, green, and blue. No alpha byte.
- kQ3PixelTypeUnknown
- Unknown pixel type.
typedef enum {
kQ3Failure = 0,
kQ3Success = 1,
kQ3StatusSize32 = 0xFFFFFFFF
} TQ3Status;
Discussion
Fundamental status type.
Constants
- kQ3Failure
- Indicates failure.
- kQ3Success
- Indicates success
typedef enum {
kQ3Off = 0,
kQ3On = 1,
kQ3SwitchSize32 = 0xFFFFFFFF
} TQ3Switch;
Discussion
Fundamental switch type.
Constants
- kQ3Off
- Off.
- kQ3On
- On.
© 1999-2008 Quesa Developers (Last Updated 5/10/2008)