Class: AggregateUniformsBatchFactory

AggregateUniformsBatchFactory

Factory for producing aggregate-uniforms batches. This is useful for shaders that must use uniforms.

new AggregateUniformsBatchFactory ()

Members

MAX_UNIFORMS number readonly

The max. uniforms until the batch is filled

Methods

_buildBatch (batch) protected

Name Type Description
batch AggregateUniformBatch

_createUniformBuffer ()

Creates an array for each uniform-name in an object.

Returns:
  • the object created (the uniform buffer)

_matchUniforms ()

Finds a matching set of uniforms in the buffer.

_newBatch ()AggregateUniformsBatch

Returns:
Type Description
AggregateUniformsBatch

_put (displayObject)boolean protected

Stores uniforms in the current batch, if possible.

If you want to override this, be sure to return beforehand if super._put returns false:

_put(displayObject: PIXI.DisplayObject): boolean
{
     if (!super._put(displayObject))
     {
         return false;
     }

     // Your logic ...
}
Name Type Description
displayObject PIXI.DisplayObject
Returns:
Type Description
boolean
  • whether uniforms can be buffered

_resetUniformBuffer (buffer)

Resets each array in the uniform buffer

Name Type Description
buffer object