From 8cf0be4b6ce3a3cd04bdbc44ecfa3c2a304a891a Mon Sep 17 00:00:00 2001 From: Ray Date: Mon, 14 Sep 2020 19:20:38 +0200 Subject: Review memory loading functions signesness --- src/text.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/text.c') diff --git a/src/text.c b/src/text.c index c9d2bfcc..cce8d98a 100644 --- a/src/text.c +++ b/src/text.c @@ -341,7 +341,7 @@ Font LoadFontEx(const char *fileName, int fontSize, int *fontChars, int charsCou unsigned char *fileData = LoadFileData(fileName, &fileSize); // Loading font from memory data - font = LoadFontFromMemory(GetFileExtension(fileName), (char *)fileData, fileSize, fontSize, fontChars, charsCount); + font = LoadFontFromMemory(GetFileExtension(fileName), fileData, fileSize, fontSize, fontChars, charsCount); RL_FREE(fileData); @@ -471,7 +471,7 @@ Font LoadFontFromImage(Image image, Color key, int firstChar) } // Load font from memory buffer, fileType refers to extension: i.e. "ttf" -Font LoadFontFromMemory(const char *fileType, const char *fileData, int dataSize, int fontSize, int *fontChars, int charsCount) +Font LoadFontFromMemory(const char *fileType, const unsigned char *fileData, int dataSize, int fontSize, int *fontChars, int charsCount) { Font font = { 0 }; @@ -511,7 +511,7 @@ Font LoadFontFromMemory(const char *fileType, const char *fileData, int dataSize // Load font data for further use // NOTE: Requires TTF font memory data and can generate SDF data -CharInfo *LoadFontData(const char *fileData, int dataSize, int fontSize, int *fontChars, int charsCount, int type) +CharInfo *LoadFontData(const unsigned char *fileData, int dataSize, int fontSize, int *fontChars, int charsCount, int type) { // NOTE: Using some SDF generation default values, // trades off precision with ability to handle *smaller* sizes -- cgit v1.2.3