64 dst->handle_refcount_ = 1;
189 verts->vertex_len = v_len;
233 const uint vertex_len =
verts->vertex_len;
237 memcpy(
verts->data,
data, vertex_len *
a->size);
241 for (
uint v = 0;
v < vertex_len;
v++) {
258 access->
size =
a->size;
281 verts->data =
nullptr;
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum const void *lists _GL_VOID_RET _GL_VOID const GLdouble *equation _GL_VOID_RET _GL_VOID GLdouble GLdouble blue _GL_VOID_RET _GL_VOID GLfloat GLfloat blue _GL_VOID_RET _GL_VOID GLint GLint blue _GL_VOID_RET _GL_VOID GLshort GLshort blue _GL_VOID_RET _GL_VOID GLubyte GLubyte blue _GL_VOID_RET _GL_VOID GLuint GLuint blue _GL_VOID_RET _GL_VOID GLushort GLushort blue _GL_VOID_RET _GL_VOID GLbyte GLbyte GLbyte alpha _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble alpha _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat alpha _GL_VOID_RET _GL_VOID GLint GLint GLint alpha _GL_VOID_RET _GL_VOID GLshort GLshort GLshort alpha _GL_VOID_RET _GL_VOID GLubyte GLubyte GLubyte alpha _GL_VOID_RET _GL_VOID GLuint GLuint GLuint alpha _GL_VOID_RET _GL_VOID GLushort GLushort GLushort alpha _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLint GLsizei GLsizei GLenum type _GL_VOID_RET _GL_VOID GLsizei GLenum GLenum const void *pixels _GL_VOID_RET _GL_VOID const void *pointer _GL_VOID_RET _GL_VOID GLdouble v _GL_VOID_RET _GL_VOID GLfloat v _GL_VOID_RET _GL_VOID GLint GLint i2 _GL_VOID_RET _GL_VOID GLint j _GL_VOID_RET _GL_VOID GLfloat param _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble GLdouble GLdouble zFar _GL_VOID_RET _GL_UINT GLdouble *equation _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLenum GLfloat *v _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLfloat *values _GL_VOID_RET _GL_VOID GLushort *values _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLenum GLdouble *params _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLsizei stride
struct GPUVertBuf GPUVertBuf
@ GPU_VERTBUF_DATA_UPLOADED
Read Guarded memory(de)allocation.
ATTR_WARN_UNUSED_RESULT const BMVert * v
static GPUBackend * get()
virtual VertBuf * vertbuf_alloc()=0
static size_t memory_usage
void resize(uint vert_len)
virtual void upload_data()=0
void init(const GPUVertFormat *format, GPUUsageType usage)
void allocate(uint vert_len)
virtual void duplicate_data(VertBuf *dst)=0
virtual void resize_data()=0
virtual void release_data()=0
virtual void acquire_data()=0
static void * vertbuf_alloc(const OpenSubdiv_Buffer *interface, const uint len)
void GPU_vertbuf_data_alloc(GPUVertBuf *verts, uint v_len)
void GPU_vertbuf_data_resize(GPUVertBuf *verts, uint v_len)
void * GPU_vertbuf_steal_data(GPUVertBuf *verts_)
uint GPU_vertbuf_get_vertex_alloc(const GPUVertBuf *verts)
void GPU_vertbuf_wrap_handle(GPUVertBuf *verts, uint64_t handle)
void * GPU_vertbuf_unmap(const GPUVertBuf *verts, const void *mapped_data)
const GPUVertFormat * GPU_vertbuf_get_format(const GPUVertBuf *verts)
void GPU_vertbuf_attr_get_raw_data(GPUVertBuf *verts_, uint a_idx, GPUVertBufRaw *access)
uint GPU_vertbuf_get_vertex_len(const GPUVertBuf *verts)
void GPU_vertbuf_data_len_set(GPUVertBuf *verts_, uint v_len)
void GPU_vertbuf_update_sub(GPUVertBuf *verts, uint start, uint len, const void *data)
GPUVertBuf * GPU_vertbuf_duplicate(GPUVertBuf *verts_)
void GPU_vertbuf_clear(GPUVertBuf *verts)
void GPU_vertbuf_handle_ref_remove(GPUVertBuf *verts)
void GPU_vertbuf_init_with_format_ex(GPUVertBuf *verts_, const GPUVertFormat *format, GPUUsageType usage)
void GPU_vertbuf_attr_fill(GPUVertBuf *verts_, uint a_idx, const void *data)
void GPU_vertbuf_attr_set(GPUVertBuf *verts_, uint a_idx, uint v_idx, const void *data)
void GPU_vertbuf_bind_as_ssbo(struct GPUVertBuf *verts, int binding)
GPUVertBufStatus GPU_vertbuf_get_status(const GPUVertBuf *verts)
void * GPU_vertbuf_get_data(const GPUVertBuf *verts)
uint GPU_vertbuf_get_memory_usage()
void GPU_vertbuf_attr_fill_stride(GPUVertBuf *verts_, uint a_idx, uint stride, const void *data)
GPUVertBuf * GPU_vertbuf_create_with_format_ex(const GPUVertFormat *format, GPUUsageType usage)
void GPU_vertbuf_use(GPUVertBuf *verts)
void GPU_vertbuf_init_build_on_device(GPUVertBuf *verts, GPUVertFormat *format, uint v_len)
const void * GPU_vertbuf_read(GPUVertBuf *verts)
void GPU_vertbuf_discard(GPUVertBuf *verts)
void GPU_vertbuf_vert_set(GPUVertBuf *verts_, uint v_idx, const void *data)
void GPU_vertbuf_bind_as_texture(struct GPUVertBuf *verts, int binding)
void GPU_vertbuf_handle_ref_add(GPUVertBuf *verts)
GPUVertBuf * GPU_vertbuf_calloc()
void GPU_vertbuf_tag_dirty(GPUVertBuf *verts)
static GPUContext * wrap(Context *ctx)
static Context * unwrap(GPUContext *ctx)
unsigned __int64 uint64_t
unsigned char * data_init