Did I find the right examples for you? yes no

All Samples(26)  |  Call(26)  |  Derive(0)  |  Import(0)
Given a data-value, try to determine number of bytes it's final form occupies

For most data-types this is arraySize() * atomic-unit-size

src/g/l/glfwpy-HEAD/examples/02_triangle_mesh.py   glfwpy(Download)
    glBindBuffer(GL_ARRAY_BUFFER, vbo_id[0])
    glBufferData(GL_ARRAY_BUFFER,
        ArrayDatatype.arrayByteCount(vertex_data),
        vertex_data, GL_STATIC_DRAW)
    glVertexAttribPointer(program.attribute_location('vin_position'),
    glBindBuffer(GL_ARRAY_BUFFER, vbo_id[1])
    glBufferData(GL_ARRAY_BUFFER,
        ArrayDatatype.arrayByteCount(normal_data),
        normal_data, GL_STATIC_DRAW)
    glVertexAttribPointer(program.attribute_location('vin_normal'),
    glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, vbo_id[2])
    glBufferData(GL_ELEMENT_ARRAY_BUFFER,
        ArrayDatatype.arrayByteCount(index_data),
        index_data, GL_STATIC_DRAW)
 

src/g/l/glfwpy-HEAD/examples/04_textured_rectangle.py   glfwpy(Download)
    # Now go ahead and fill this bound buffer with some data
    glBufferData(GL_ARRAY_BUFFER,
        ArrayDatatype.arrayByteCount(vertex_data),
        vertex_data, GL_STATIC_DRAW)
 
    glBindBuffer(GL_ARRAY_BUFFER, vbo_id[1])
    glBufferData(GL_ARRAY_BUFFER,
        ArrayDatatype.arrayByteCount(uv_data),
        uv_data, GL_STATIC_DRAW)
    glVertexAttribPointer(program.attribute_location('vin_uv'),

src/g/l/glfwpy-HEAD/examples/03_instanced_drawing.py   glfwpy(Download)
 
    glBindBuffer(GL_ARRAY_BUFFER, vbo_id[0])
    glBufferData(GL_ARRAY_BUFFER, ArrayDatatype.arrayByteCount(vertex_data), vertex_data, GL_STATIC_DRAW)
    glVertexAttribPointer(program.attribute_location('vin_position'), 3, GL_FLOAT, GL_FALSE, 0, ctypes.c_voidp(0))
    glEnableVertexAttribArray(0)
 
    glBindBuffer(GL_ARRAY_BUFFER, vbo_id[1])
    glBufferData(GL_ARRAY_BUFFER, ArrayDatatype.arrayByteCount(color_data), color_data, GL_STATIC_DRAW)

src/g/l/glfwpy-HEAD/examples/01_triangle.py   glfwpy(Download)
    # Now go ahead and fill this bound buffer with some data
    glBufferData(GL_ARRAY_BUFFER,
        ArrayDatatype.arrayByteCount(vertex_data),
        vertex_data, GL_STATIC_DRAW)
 
    glBindBuffer(GL_ARRAY_BUFFER, vbo_id[1])
    glBufferData(GL_ARRAY_BUFFER,
        ArrayDatatype.arrayByteCount(color_data),
        color_data, GL_STATIC_DRAW)
    glVertexAttribPointer(program.attribute_location('vin_color'),

src/e/p/epimorphism-HEAD/_lib/sources/OpenGL/GL/VERSION/GL_1_5.py   epimorphism(Download)
def _sizeOfArrayInput( pyArgs, index, wrapper ):
    return (
        arrays.ArrayDatatype.arrayByteCount( pyArgs[index] )
    )
 
    data = ArrayDatatype.asArray( data )
    if size is None:
        size = ArrayDatatype.arrayByteCount( data )
    return baseOperation( target, size, data, usage )
 
    data = ArrayDatatype.asArray( data )
    if size is None:
        size = ArrayDatatype.arrayByteCount( data )
    return baseOperation( target, offset, size, data )
 

src/p/y/PyOpenGL-3.1.0b2/OpenGL/GL/VERSION/GL_1_5.py   PyOpenGL(Download)
def _sizeOfArrayInput( pyArgs, index, wrapper ):
    return (
        arrays.ArrayDatatype.arrayByteCount( pyArgs[index] )
    )
 
    data = ArrayDatatype.asArray( data )
    if size is None:
        size = ArrayDatatype.arrayByteCount( data )
    return baseOperation( target, size, data, usage )
 
    data = ArrayDatatype.asArray( data )
    if size is None:
        size = ArrayDatatype.arrayByteCount( data )
    return baseOperation( target, offset, size, data )
 

src/e/p/epimorphism-HEAD/_lib/sources/OpenGL/GL/ARB/vertex_buffer_object.py   epimorphism(Download)
def _sizeOfArrayInput( pyArgs, index, wrapper ):
    return (
        arrays.ArrayDatatype.arrayByteCount( pyArgs[index] )
    )
 
    data = ArrayDatatype.asArray( data )
    if size is None:
        size = ArrayDatatype.arrayByteCount( data )
    return baseOperation( target, size, data, usage )
 
    data = ArrayDatatype.asArray( data )
    if size is None:
        size = ArrayDatatype.arrayByteCount( data )
    return baseOperation( target, offset, size, data )
 

src/p/y/PyOpenGL-3.1.0b2/OpenGL/GL/ARB/vertex_buffer_object.py   PyOpenGL(Download)
def _sizeOfArrayInput( pyArgs, index, wrapper ):
    return (
        arrays.ArrayDatatype.arrayByteCount( pyArgs[index] )
    )
 
    data = ArrayDatatype.asArray( data )
    if size is None:
        size = ArrayDatatype.arrayByteCount( data )
    return baseOperation( target, size, data, usage )
 
    data = ArrayDatatype.asArray( data )
    if size is None:
        size = ArrayDatatype.arrayByteCount( data )
    return baseOperation( target, offset, size, data )
 

src/c/h/chemlab-0.3/chemlab/graphics/buffers.py   chemlab(Download)
 
    glBindBuffer(GL_ARRAY_BUFFER, self.buffer)
    glBufferData(GL_ARRAY_BUFFER, ADT.arrayByteCount(data),
                 ADT.voidDataPointer(data), usage)
    glBindBuffer(GL_ARRAY_BUFFER, 0)
  def set_data(self, data):
    self.bind()
    glBufferData(GL_ARRAY_BUFFER, ADT.arrayByteCount(data), ADT.voidDataPointer(data), self.usage)
    self.unbind()
 

src/c/h/chemlab-HEAD/chemlab/graphics/buffers.py   chemlab(Download)
 
    glBindBuffer(GL_ARRAY_BUFFER, self.buffer)
    glBufferData(GL_ARRAY_BUFFER, ADT.arrayByteCount(data),
                 ADT.voidDataPointer(data), usage)
    glBindBuffer(GL_ARRAY_BUFFER, 0)
  def set_data(self, data):
    self.bind()
    glBufferData(GL_ARRAY_BUFFER, ADT.arrayByteCount(data), ADT.voidDataPointer(data), self.usage)
    self.unbind()
 

  1 | 2  Next