com.io7m.r2.core

## Interface R2InstanceBatchedType

- All Superinterfaces:
    R2InstanceType
  All Known Subinterfaces:
    R2InstanceBatchedDynamicType
  All Known Implementing Classes:
    R2InstanceBatchedDynamic

      public interface R2InstanceBatchedType
      extends R2InstanceType

  The type of batched instances.

  A batch consists of a set of one or more vertex buffers containing mesh data, and a vertex buffer containing a set of transforms - one per rendered object.

  The primary use case for batched instances is rendering a lot of copies of the same mesh in a single draw call.

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `com.io7m.jcanephora.core.JCGLArrayObjectType` | `arrayObject()`
    `int` | `renderCount()`
    `void` | `update(com.io7m.jcanephora.core.api.JCGLInterfaceGL33Type g, R2TransformContextType context)` Update any data required for rendering on the GPU.

    - ### Methods inherited from interface com.io7m.r2.core.R2InstanceType

      `instanceID`

- - ### Method Detail

    - #### arrayObject

          com.io7m.jcanephora.core.JCGLArrayObjectType arrayObject()

      Returns:
        The instance array object

    - #### update

          void update(com.io7m.jcanephora.core.api.JCGLInterfaceGL33Type g,
                      R2TransformContextType context)

      Update any data required for rendering on the GPU.
      Parameters:
        `context` - The transform context
        `g` - An OpenGL interface

    - #### renderCount

          int renderCount()

      Returns:
        The number of instances that will be rendered.

Copyright © 2017 <code@io7m.com> http://io7m.com