Class descriptionObjects of this class represent GPU-accessible memory buffers. Buffer objects can be used to store vertex data and to update or read pixel data from textures and framebuffers without CPU involvement. The data inside buffer objects may be resident in main memory or different parts of GPU memory; the graphics driver will choose a location for a buffer based on usage hints specified when the buffer object is constructed with <buffer> or byte-array>buffer:

•

upload-pattern is one of the buffer-upload-pattern values and indicates how frequently the data in the buffer will be updated with new data from CPU memory.

•

usage-pattern is one of the buffer-usage-pattern values and indicates how frequently the data in the buffer will be updated with new data from CPU memory.

•

kind is one of the buffer-kind values and indicates the primary purpose of the buffer.

These settings are only performance hints and do not restrict the usage of the buffer in any way. For example, a buffer constructed as a vertex-buffer with static-upload can still receive pixel data as though it were a pixel-pack-buffer, and can still be updated with copy-buffer or update-buffer. However, performance may be worse when actual usage conflicts with declared usage.