Fixed GCC Warnings
This commit is contained in:
parent
af66e751db
commit
5a5b959580
4
src/external/rl_gputex.h
vendored
4
src/external/rl_gputex.h
vendored
|
|
@ -771,7 +771,11 @@ void *rl_load_astc_from_memory(const unsigned char *file_data, unsigned int file
|
||||||
// Module Internal Functions Definition
|
// Module Internal Functions Definition
|
||||||
//----------------------------------------------------------------------------------
|
//----------------------------------------------------------------------------------
|
||||||
// Get pixel data size in bytes for certain pixel format
|
// Get pixel data size in bytes for certain pixel format
|
||||||
|
#ifdef __GNUC__
|
||||||
|
static inline int get_pixel_data_size(int width, int height, int format)
|
||||||
|
#else
|
||||||
static int get_pixel_data_size(int width, int height, int format)
|
static int get_pixel_data_size(int width, int height, int format)
|
||||||
|
#endif // __GNUC__
|
||||||
{
|
{
|
||||||
int data_size = 0; // Size in bytes
|
int data_size = 0; // Size in bytes
|
||||||
int bpp = 0; // Bits per pixel
|
int bpp = 0; // Bits per pixel
|
||||||
|
|
|
||||||
4
src/external/stb_truetype.h
vendored
4
src/external/stb_truetype.h
vendored
|
|
@ -500,7 +500,11 @@ int main(int arg, char **argv)
|
||||||
#define __STB_INCLUDE_STB_TRUETYPE_H__
|
#define __STB_INCLUDE_STB_TRUETYPE_H__
|
||||||
|
|
||||||
#ifdef STBTT_STATIC
|
#ifdef STBTT_STATIC
|
||||||
|
#ifdef __GNUC__
|
||||||
|
#define STBTT_DEF static inline
|
||||||
|
#else
|
||||||
#define STBTT_DEF static
|
#define STBTT_DEF static
|
||||||
|
#endif // __GNUC__
|
||||||
#else
|
#else
|
||||||
#define STBTT_DEF extern
|
#define STBTT_DEF extern
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
6
src/external/stb_vorbis.h
vendored
6
src/external/stb_vorbis.h
vendored
|
|
@ -897,7 +897,7 @@ static int stbv_error(stbv_vorb *f, enum STBVorbisError e)
|
||||||
#define stbv_array_size_required(count,size) (count*(sizeof(void *)+(size)))
|
#define stbv_array_size_required(count,size) (count*(sizeof(void *)+(size)))
|
||||||
|
|
||||||
#define stbv_temp_alloc(f,size) (f->alloc.alloc_buffer ? stbv_setup_temp_malloc(f,size) : alloca(size))
|
#define stbv_temp_alloc(f,size) (f->alloc.alloc_buffer ? stbv_setup_temp_malloc(f,size) : alloca(size))
|
||||||
#define stbv_temp_free(f,p) 0
|
#define stbv_temp_free(f,p) ((void)0)
|
||||||
#define stbv_temp_alloc_save(f) ((f)->temp_offset)
|
#define stbv_temp_alloc_save(f) ((f)->temp_offset)
|
||||||
#define stbv_temp_alloc_restore(f,p) ((f)->temp_offset = (p))
|
#define stbv_temp_alloc_restore(f,p) ((f)->temp_offset = (p))
|
||||||
|
|
||||||
|
|
@ -3933,7 +3933,7 @@ static int stbv_start_decoder(stbv_vorb *f)
|
||||||
g->sorted_order[j] = (stbv_uint8) p[j].id;
|
g->sorted_order[j] = (stbv_uint8) p[j].id;
|
||||||
// precompute the stbv_neighbors
|
// precompute the stbv_neighbors
|
||||||
for (j=2; j < g->values; ++j) {
|
for (j=2; j < g->values; ++j) {
|
||||||
int low,hi;
|
int low = 0, hi = 0;
|
||||||
stbv_neighbors(g->Xlist, j, &low,&hi);
|
stbv_neighbors(g->Xlist, j, &low,&hi);
|
||||||
g->stbv_neighbors[j][0] = low;
|
g->stbv_neighbors[j][0] = low;
|
||||||
g->stbv_neighbors[j][1] = hi;
|
g->stbv_neighbors[j][1] = hi;
|
||||||
|
|
@ -4611,7 +4611,7 @@ static int stbv_seek_to_sample_coarse(stb_vorbis *f, stbv_uint32 sample_number)
|
||||||
StbvProbedPage left, right, mid;
|
StbvProbedPage left, right, mid;
|
||||||
int i, start_seg_with_known_loc, end_pos, page_start;
|
int i, start_seg_with_known_loc, end_pos, page_start;
|
||||||
stbv_uint32 delta, stream_length, padding;
|
stbv_uint32 delta, stream_length, padding;
|
||||||
double offset, bytes_per_sample;
|
double offset = 0.0f, bytes_per_sample = 0.0f;
|
||||||
int probe = 0;
|
int probe = 0;
|
||||||
|
|
||||||
// find the last page and validate the target sample
|
// find the last page and validate the target sample
|
||||||
|
|
|
||||||
|
|
@ -4732,7 +4732,8 @@ static BoneInfo *LoadBoneInfoGLTF(cgltf_skin skin, int *boneCount)
|
||||||
for (unsigned int i = 0; i < skin.joints_count; i++)
|
for (unsigned int i = 0; i < skin.joints_count; i++)
|
||||||
{
|
{
|
||||||
cgltf_node node = *skin.joints[i];
|
cgltf_node node = *skin.joints[i];
|
||||||
strncpy(bones[i].name, node.name, sizeof(bones[i].name));
|
strcat(bones[i].name, node.name);
|
||||||
|
// strncpy(bones[i].name, node.name, sizeof(bones[i].name));
|
||||||
|
|
||||||
// Find parent bone index
|
// Find parent bone index
|
||||||
unsigned int parentIndex = -1;
|
unsigned int parentIndex = -1;
|
||||||
|
|
@ -5896,7 +5897,8 @@ static ModelAnimation *LoadModelAnimationsM3D(const char *fileName, unsigned int
|
||||||
for (i = 0; i < (int)m3d->numbone; i++)
|
for (i = 0; i < (int)m3d->numbone; i++)
|
||||||
{
|
{
|
||||||
animations[a].bones[i].parent = m3d->bone[i].parent;
|
animations[a].bones[i].parent = m3d->bone[i].parent;
|
||||||
strncpy(animations[a].bones[i].name, m3d->bone[i].name, sizeof(animations[a].bones[i].name));
|
strcat(animations[a].bones[i].name, m3d->bone[i].name);
|
||||||
|
// strncpy(animations[a].bones[i].name, m3d->bone[i].name, sizeof(animations[a].bones[i].name));
|
||||||
}
|
}
|
||||||
|
|
||||||
// A special, never transformed "no bone" bone, used for boneless vertices
|
// A special, never transformed "no bone" bone, used for boneless vertices
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user