32#include "storage_buffer.h" 
   41        template<
typename Type>
 
   67                        : 
StorageBuffer(gc, data, size * sizeof(Type), sizeof(Type), usage)
 
 
   72                        : 
StorageBuffer(gc, data.empty() ? (Type*)0 : &data[0], data.size() * sizeof(Type), sizeof(Type), usage)
 
 
   95                                size = size * 
sizeof(Type);
 
 
  103                                size = size * 
sizeof(Type);
 
 
 
Interface to drawing graphics.
Definition graphic_context.h:257
Storage Buffer.
Definition storage_buffer.h:47
void copy_from(GraphicContext &gc, TransferBuffer &buffer, int dest_pos=0, int src_pos=0, int size=-1)
Copies data from transfer buffer.
void copy_to(GraphicContext &gc, TransferBuffer &buffer, int dest_pos=0, int src_pos=0, int size=-1)
Copies data to transfer buffer.
void upload_data(GraphicContext &gc, const void *data, int size)
Uploads data to storage buffer.
Storage Buffer Vector.
Definition storage_vector.h:43
void copy_from(GraphicContext &gc, TransferVector< Type > &buffer, int dest_pos=0, int src_pos=0, int size=-1)
Copies data from transfer buffer.
Definition storage_vector.h:92
void upload_data(GraphicContext &gc, const std::vector< Type > &data)
Uploads data to storage buffer.
Definition storage_vector.h:85
StorageVector(GraphicContext &gc, Type *data, int size, BufferUsage usage=BufferUsage::static_draw)
Constructs a ElementArrayBuffer.
Definition storage_vector.h:66
StorageVector(GraphicContext &gc, const std::vector< Type > &data, BufferUsage usage=BufferUsage::static_draw)
Definition storage_vector.h:71
void upload_data(GraphicContext &gc, const Type *data, int size)
Uploads data to storage buffer.
Definition storage_vector.h:79
StorageVector()
Constructs a null instance.
Definition storage_vector.h:46
void copy_to(GraphicContext &gc, TransferVector< Type > &buffer, int dest_pos=0, int src_pos=0, int size=-1)
Copies data to transfer buffer.
Definition storage_vector.h:100
StorageVector(GraphicContext &gc, int size, BufferUsage usage=BufferUsage::static_draw)
Constructs a ElementArrayBuffer.
Definition storage_vector.h:55
Transfer Vector.
Definition transfer_vector.h:42
BufferUsage
Array Buffer usage enum.
Definition buffer_usage.h:39