Phaser API Documentation

  Version: 
createAttributes(attributes)

Description:

Takes the vertex attributes config and parses it, creating the resulting array that is stored in this shaders attributes property, calculating the offset, normalization and location in the process.

Calling this method resets WebGLShader.attributes, WebGLShader.vertexSize and WebGLShader.vertexComponentCount.

It is called automatically when this class is created, but can be called manually if required.

Parameters:

name type description
attributes Array.<Phaser.Types.Renderer.WebGL.WebGLPipelineAttributeConfig>

An array of attributes configs.

Since: 3.50.0