.\" Automatically generated by Pandoc 3.1.11.1 .\" .TH "ALLEGRO_PRIM_STORAGE" "3" "" "Allegro reference manual" "" .SH NAME ALLEGRO_PRIM_STORAGE \- Allegro 5 API .SH SYNOPSIS .IP .EX #include typedef enum ALLEGRO_PRIM_STORAGE .EE .SH DESCRIPTION Enumerates the types of storage an attribute of a custom vertex may be stored in. Many of these can only be used for ALLEGRO_PRIM_USER_ATTR attributes and can only be accessed via shaders. Usually no matter what the storage is specified the attribute gets converted to single precision floating point when the shader is run. Despite that, it may be advantageous to use more dense storage formats (e.g.\ ALLEGRO_PRIM_NORMALIZED_UBYTE_4 instead of ALLEGRO_PRIM_FLOAT_4) when bandwidth (amount of memory sent to the GPU) is an issue but precision is not. .IP \[bu] 2 ALLEGRO_PRIM_FLOAT_1 \- A single float .RS 2 .PP Since: 5.1.6 .RE .IP \[bu] 2 ALLEGRO_PRIM_FLOAT_2 \- A doublet of floats .IP \[bu] 2 ALLEGRO_PRIM_FLOAT_3 \- A triplet of floats .IP \[bu] 2 ALLEGRO_PRIM_FLOAT_4 \- A quad of floats .RS 2 .PP Since: 5.1.6 .RE .IP \[bu] 2 ALLEGRO_PRIM_SHORT_2 \- A doublet of shorts .IP \[bu] 2 ALLEGRO_PRIM_SHORT_4 \- A quad of shorts .RS 2 .PP Since: 5.1.6 .RE .IP \[bu] 2 ALLEGRO_PRIM_UBYTE_4 \- A quad of unsigned bytes .RS 2 .PP Since: 5.1.6 .RE .IP \[bu] 2 ALLEGRO_PRIM_NORMALIZED_SHORT_2 \- A doublet of shorts. Before being sent to the shader, each component is divided by 32767. Each component of the resultant float doublet ranges between \-1.0 and 1.0 .RS 2 .PP Since: 5.1.6 .RE .IP \[bu] 2 ALLEGRO_PRIM_NORMALIZED_SHORT_4 \- A quad of shorts. Before being sent to the shader, each component is divided by 32767. Each component of the resultant float quad ranges between \-1.0 and 1.0 .RS 2 .PP Since: 5.1.6 .RE .IP \[bu] 2 ALLEGRO_PRIM_NORMALIZED_UBYTE_4 \- A quad of unsigned bytes. Before being sent to the shader, each component is divided by 255. Each component of the resultant float quad ranges between 0.0 and 1.0 .RS 2 .PP Since: 5.1.6 .RE .IP \[bu] 2 ALLEGRO_PRIM_NORMALIZED_USHORT_2 \- A doublet of unsigned shorts. Before being sent to the shader, each component is divided by 65535. Each component of the resultant float doublet ranges between 0.0 and 1.0 .RS 2 .PP Since: 5.1.6 .RE .IP \[bu] 2 ALLEGRO_PRIM_NORMALIZED_USHORT_4 \- A quad of unsigned shorts. Before being sent to the shader, each component is divided by 65535. Each component of the resultant float quad ranges between 0.0 and 1.0 .RS 2 .PP Since: 5.1.6 .RE .IP \[bu] 2 ALLEGRO_PRIM_HALF_FLOAT_2 \- A doublet of half\-precision floats. Note that this storage format is not supported on all platforms. al_create_vertex_decl(3) will return NULL if you use it on those platforms .RS 2 .PP Since: 5.1.6 .RE .IP \[bu] 2 ALLEGRO_PRIM_HALF_FLOAT_4 \- A quad of half\-precision floats. Note that this storage format is not supported on all platforms. al_create_vertex_decl(3) will return NULL if you use it on those platforms. .RS 2 .PP Since: 5.1.6 .RE .SH SEE ALSO ALLEGRO_PRIM_ATTR(3)