mirror of
https://github.com/raysan5/raylib.git
synced 2025-10-05 01:16:28 +00:00
[rmodels] Optional GPU skinning (#4321)
* Added optional GPU skinning * Added skinned bone matrices support for different file formats. * Moved new shader locations to end of enum to avoid breaking existing examples. Added gpu skinning on drawing of instanced meshes. * Added GPU skinning example. * Removed variable declaration to avoid shadowing warning.
This commit is contained in:
16
src/config.h
16
src/config.h
@@ -113,13 +113,15 @@
|
||||
#define RL_CULL_DISTANCE_FAR 1000.0 // Default projection matrix far cull distance
|
||||
|
||||
// Default shader vertex attribute locations
|
||||
#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION 0
|
||||
#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD 1
|
||||
#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_NORMAL 2
|
||||
#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_COLOR 3
|
||||
#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_TANGENT 4
|
||||
#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD2 5
|
||||
#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_INDICES 6
|
||||
#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_POSITION 0
|
||||
#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD 1
|
||||
#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_NORMAL 2
|
||||
#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_COLOR 3
|
||||
#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_TANGENT 4
|
||||
#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_TEXCOORD2 5
|
||||
#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_BONEIDS 6
|
||||
#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_BONEWEIGHTS 7
|
||||
#define RL_DEFAULT_SHADER_ATTRIB_LOCATION_INDICES 8
|
||||
|
||||
// Default shader vertex attribute names to set location points
|
||||
// NOTE: When a new shader is loaded, the following locations are tried to be set for convenience
|
||||
|
Reference in New Issue
Block a user