Describes an S3D surface used for framebuffer, zbuffer and textures.
Declaration:
TS3DTK_SURFACE = record sfOffset: ULONG; sfWidth: ULONG; sfHeight: ULONG; sfFormat: ULONG; reserved: array [0..4] of ULONG; end;
Fields:
Description:
For surfaces containing drawable 2D image data (e.g. framebuffer, sprites, etc), the format can be one of the following values:
For textures the format can be one of the following values:
For zbuffers the only acceptable value is S3DTK_Z16 for 16bit per pixel.
Surface location:
Surfaces can reside in either video or system memory. When a surface is in system memory the sfOffset field is the linear memory address (a 32bit pointer casted to ULONG) and their format must be OR'd with S3DTK_SYSTEM. For surfaces in video memory the field is actually the offset from the framebuffer which can be calculated as explained in the Quickstart section. The format can be OR'd with S3DTK_VIDEO but this is just for documentation purposes as the value of that constant is 0.
Unit: S3DTK
See Also: