Skip to main content

components

Function components 

Source
pub fn components(ty: u32) -> Option<usize>
Expand description

The number of components of a numeric CGtype (Cg’s cg_datatypes.h, numbered from CG_TYPE_START_ENUM = 1024): its half, float, fixed, int and bool scalars (1), vectors of 1 to 4 and matrices of 1 to 4 rows by 1 to 4 columns. None for the samplers, strings, programs and textures, and for a number outside the table.