Overview Function List GLOD Web Site


glodReadbackObject - Packs an object's LOD Hierarchy into a user specified buffer for later use.


void glodReadbackObject(GLuint name, GLvoid* data)


The name of the object to read back.

A pointer to the data buffer that will recieve the readback object.


Readback facilities are provided in GLOD to compensate for the fact that simplification is a slow process. This call allows you to, in an advance pre-process, create and simplify an object, then read it back and save it for later use.

GLOD reads back these objects in a binary format. This readback mechanism stores only the hierarchy data, including geometry and patch identification numbers. It does not store the object number nor the group identifier for the object, nor the current adapted state of the object. These must be recreated by the user in subsequent glodLoadObject() and glodAdaptGroup() calls.


One must allocate the data pointer before calling glodReadbackObject. Determine the size of the object to be readback using the glodGetObjectParameter() call using GLOD_READBACK_SIZE as the parameter name to get. You can then allocate the readback buffer and call glodReadbackObject().

For example:

  void* data; int data_size;
  glodGetObjectParameter(MY_OBJ_NAME, GLOD_READBACK_SIZE,
  data = malloc(data_size);
  glodReadbackObject(MY_OBJ_NAME, data);


GLOD_INVALID_NAME is generated if an object of the given name does not exist.

Last modified: 06/10/04 06:32:22 PM