Review some comments
This commit is contained in:
parent
beeac18eb1
commit
e3ba11bead
1 changed files with 48 additions and 54 deletions
102
src/raylib.h
102
src/raylib.h
|
@ -160,13 +160,14 @@
|
||||||
|
|
||||||
// Temporal hacks to avoid breaking old codebases using
|
// Temporal hacks to avoid breaking old codebases using
|
||||||
// deprecated raylib implementation or definitions
|
// deprecated raylib implementation or definitions
|
||||||
#define FormatText TextFormat
|
#define SpriteFont Font
|
||||||
#define LoadText LoadFileText
|
#define FormatText TextFormat
|
||||||
#define GetExtension GetFileExtension
|
#define LoadText LoadFileText
|
||||||
#define GetImageData LoadImageColors
|
#define GetExtension GetFileExtension
|
||||||
#define FILTER_POINT TEXTURE_FILTER_POINT
|
#define GetImageData LoadImageColors
|
||||||
#define FILTER_BILINEAR TEXTURE_FILTER_BILINEAR
|
#define FILTER_POINT TEXTURE_FILTER_POINT
|
||||||
#define MAP_DIFFUSE MATERIAL_MAP_DIFFUSE
|
#define FILTER_BILINEAR TEXTURE_FILTER_BILINEAR
|
||||||
|
#define MAP_DIFFUSE MATERIAL_MAP_DIFFUSE
|
||||||
#define UNCOMPRESSED_R8G8B8A8 PIXELFORMAT_UNCOMPRESSED_R8G8B8A8
|
#define UNCOMPRESSED_R8G8B8A8 PIXELFORMAT_UNCOMPRESSED_R8G8B8A8
|
||||||
|
|
||||||
//----------------------------------------------------------------------------------
|
//----------------------------------------------------------------------------------
|
||||||
|
@ -176,23 +177,23 @@
|
||||||
#if defined(__STDC__) && __STDC_VERSION__ >= 199901L
|
#if defined(__STDC__) && __STDC_VERSION__ >= 199901L
|
||||||
#include <stdbool.h>
|
#include <stdbool.h>
|
||||||
#elif !defined(__cplusplus) && !defined(bool)
|
#elif !defined(__cplusplus) && !defined(bool)
|
||||||
typedef enum { false, true } bool;
|
typedef enum bool { false, true } bool;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// Vector2 type
|
// Vector2, 2 components
|
||||||
typedef struct Vector2 {
|
typedef struct Vector2 {
|
||||||
float x; // Vector x component
|
float x; // Vector x component
|
||||||
float y; // Vector y component
|
float y; // Vector y component
|
||||||
} Vector2;
|
} Vector2;
|
||||||
|
|
||||||
// Vector3 type
|
// Vector3, 3 components
|
||||||
typedef struct Vector3 {
|
typedef struct Vector3 {
|
||||||
float x; // Vector x component
|
float x; // Vector x component
|
||||||
float y; // Vector y component
|
float y; // Vector y component
|
||||||
float z; // Vector z component
|
float z; // Vector z component
|
||||||
} Vector3;
|
} Vector3;
|
||||||
|
|
||||||
// Vector4 type
|
// Vector4, 4 components
|
||||||
typedef struct Vector4 {
|
typedef struct Vector4 {
|
||||||
float x; // Vector x component
|
float x; // Vector x component
|
||||||
float y; // Vector y component
|
float y; // Vector y component
|
||||||
|
@ -200,10 +201,10 @@ typedef struct Vector4 {
|
||||||
float w; // Vector w component
|
float w; // Vector w component
|
||||||
} Vector4;
|
} Vector4;
|
||||||
|
|
||||||
// Quaternion type, same as Vector4
|
// Quaternion, 4 components (Vector4 alias)
|
||||||
typedef Vector4 Quaternion;
|
typedef Vector4 Quaternion;
|
||||||
|
|
||||||
// Matrix type (OpenGL style 4x4 - right handed, column major)
|
// Matrix, 4x4 components, column major, OpenGL style, right handed
|
||||||
typedef struct Matrix {
|
typedef struct Matrix {
|
||||||
float m0, m4, m8, m12; // Matrix first row (4 components)
|
float m0, m4, m8, m12; // Matrix first row (4 components)
|
||||||
float m1, m5, m9, m13; // Matrix second row (4 components)
|
float m1, m5, m9, m13; // Matrix second row (4 components)
|
||||||
|
@ -211,7 +212,7 @@ typedef struct Matrix {
|
||||||
float m3, m7, m11, m15; // Matrix fourth row (4 components)
|
float m3, m7, m11, m15; // Matrix fourth row (4 components)
|
||||||
} Matrix;
|
} Matrix;
|
||||||
|
|
||||||
// Color type, RGBA (32bit)
|
// Color, 4 components, R8G8B8A8 (32bit)
|
||||||
typedef struct Color {
|
typedef struct Color {
|
||||||
unsigned char r; // Color red value
|
unsigned char r; // Color red value
|
||||||
unsigned char g; // Color green value
|
unsigned char g; // Color green value
|
||||||
|
@ -219,7 +220,7 @@ typedef struct Color {
|
||||||
unsigned char a; // Color alpha value
|
unsigned char a; // Color alpha value
|
||||||
} Color;
|
} Color;
|
||||||
|
|
||||||
// Rectangle type
|
// Rectangle, 4 components
|
||||||
typedef struct Rectangle {
|
typedef struct Rectangle {
|
||||||
float x; // Rectangle top-left corner position x
|
float x; // Rectangle top-left corner position x
|
||||||
float y; // Rectangle top-left corner position y
|
float y; // Rectangle top-left corner position y
|
||||||
|
@ -227,8 +228,7 @@ typedef struct Rectangle {
|
||||||
float height; // Rectangle height
|
float height; // Rectangle height
|
||||||
} Rectangle;
|
} Rectangle;
|
||||||
|
|
||||||
// Image type, bpp always RGBA (32bit)
|
// Image, pixel data stored in CPU memory (RAM)
|
||||||
// NOTE: Data stored in CPU memory (RAM)
|
|
||||||
typedef struct Image {
|
typedef struct Image {
|
||||||
void *data; // Image raw data
|
void *data; // Image raw data
|
||||||
int width; // Image base width
|
int width; // Image base width
|
||||||
|
@ -237,8 +237,7 @@ typedef struct Image {
|
||||||
int format; // Data format (PixelFormat type)
|
int format; // Data format (PixelFormat type)
|
||||||
} Image;
|
} Image;
|
||||||
|
|
||||||
// Texture type
|
// Texture, tex data stored in GPU memory (VRAM)
|
||||||
// NOTE: Data stored in GPU memory
|
|
||||||
typedef struct Texture {
|
typedef struct Texture {
|
||||||
unsigned int id; // OpenGL texture id
|
unsigned int id; // OpenGL texture id
|
||||||
int width; // Texture base width
|
int width; // Texture base width
|
||||||
|
@ -247,23 +246,23 @@ typedef struct Texture {
|
||||||
int format; // Data format (PixelFormat type)
|
int format; // Data format (PixelFormat type)
|
||||||
} Texture;
|
} Texture;
|
||||||
|
|
||||||
// Texture2D type, same as Texture
|
// Texture2D, same as Texture
|
||||||
typedef Texture Texture2D;
|
typedef Texture Texture2D;
|
||||||
|
|
||||||
// TextureCubemap type, actually, same as Texture
|
// TextureCubemap, same as Texture
|
||||||
typedef Texture TextureCubemap;
|
typedef Texture TextureCubemap;
|
||||||
|
|
||||||
// RenderTexture type, for texture rendering
|
// RenderTexture, fbo for texture rendering
|
||||||
typedef struct RenderTexture {
|
typedef struct RenderTexture {
|
||||||
unsigned int id; // OpenGL framebuffer object id
|
unsigned int id; // OpenGL framebuffer object id
|
||||||
Texture texture; // Color buffer attachment texture
|
Texture texture; // Color buffer attachment texture
|
||||||
Texture depth; // Depth buffer attachment texture
|
Texture depth; // Depth buffer attachment texture
|
||||||
} RenderTexture;
|
} RenderTexture;
|
||||||
|
|
||||||
// RenderTexture2D type, same as RenderTexture
|
// RenderTexture2D, same as RenderTexture
|
||||||
typedef RenderTexture RenderTexture2D;
|
typedef RenderTexture RenderTexture2D;
|
||||||
|
|
||||||
// N-Patch layout info
|
// NPatchInfo, n-patch layout info
|
||||||
typedef struct NPatchInfo {
|
typedef struct NPatchInfo {
|
||||||
Rectangle source; // Texture source rectangle
|
Rectangle source; // Texture source rectangle
|
||||||
int left; // Left border offset
|
int left; // Left border offset
|
||||||
|
@ -273,7 +272,7 @@ typedef struct NPatchInfo {
|
||||||
int layout; // Layout of the n-patch: 3x3, 1x3 or 3x1
|
int layout; // Layout of the n-patch: 3x3, 1x3 or 3x1
|
||||||
} NPatchInfo;
|
} NPatchInfo;
|
||||||
|
|
||||||
// Font character info
|
// CharInfo, font character info
|
||||||
typedef struct CharInfo {
|
typedef struct CharInfo {
|
||||||
int value; // Character value (Unicode)
|
int value; // Character value (Unicode)
|
||||||
int offsetX; // Character offset X when drawing
|
int offsetX; // Character offset X when drawing
|
||||||
|
@ -282,7 +281,7 @@ typedef struct CharInfo {
|
||||||
Image image; // Character image data
|
Image image; // Character image data
|
||||||
} CharInfo;
|
} CharInfo;
|
||||||
|
|
||||||
// Font type, includes texture and charSet array data
|
// Font, font texture and CharInfo array data
|
||||||
typedef struct Font {
|
typedef struct Font {
|
||||||
int baseSize; // Base size (default chars height)
|
int baseSize; // Base size (default chars height)
|
||||||
int charsCount; // Number of characters
|
int charsCount; // Number of characters
|
||||||
|
@ -292,9 +291,7 @@ typedef struct Font {
|
||||||
CharInfo *chars; // Characters info data
|
CharInfo *chars; // Characters info data
|
||||||
} Font;
|
} Font;
|
||||||
|
|
||||||
#define SpriteFont Font // SpriteFont type fallback, defaults to Font
|
// Camera, defines position/orientation in 3d space
|
||||||
|
|
||||||
// Camera type, defines a camera position/orientation in 3d space
|
|
||||||
typedef struct Camera3D {
|
typedef struct Camera3D {
|
||||||
Vector3 position; // Camera position
|
Vector3 position; // Camera position
|
||||||
Vector3 target; // Camera target it looks-at
|
Vector3 target; // Camera target it looks-at
|
||||||
|
@ -305,7 +302,7 @@ typedef struct Camera3D {
|
||||||
|
|
||||||
typedef Camera3D Camera; // Camera type fallback, defaults to Camera3D
|
typedef Camera3D Camera; // Camera type fallback, defaults to Camera3D
|
||||||
|
|
||||||
// Camera2D type, defines a 2d camera
|
// Camera2D, defines position/orientation in 2d space
|
||||||
typedef struct Camera2D {
|
typedef struct Camera2D {
|
||||||
Vector2 offset; // Camera offset (displacement from target)
|
Vector2 offset; // Camera offset (displacement from target)
|
||||||
Vector2 target; // Camera target (rotation and zoom origin)
|
Vector2 target; // Camera target (rotation and zoom origin)
|
||||||
|
@ -313,8 +310,7 @@ typedef struct Camera2D {
|
||||||
float zoom; // Camera zoom (scaling), should be 1.0f by default
|
float zoom; // Camera zoom (scaling), should be 1.0f by default
|
||||||
} Camera2D;
|
} Camera2D;
|
||||||
|
|
||||||
// Vertex data definning a mesh
|
// Mesh, vertex data and vao/vbo
|
||||||
// NOTE: Data stored in CPU memory (and GPU)
|
|
||||||
typedef struct Mesh {
|
typedef struct Mesh {
|
||||||
int vertexCount; // Number of vertices stored in arrays
|
int vertexCount; // Number of vertices stored in arrays
|
||||||
int triangleCount; // Number of triangles stored (indexed or not)
|
int triangleCount; // Number of triangles stored (indexed or not)
|
||||||
|
@ -339,40 +335,40 @@ typedef struct Mesh {
|
||||||
unsigned int *vboId; // OpenGL Vertex Buffer Objects id (default vertex data)
|
unsigned int *vboId; // OpenGL Vertex Buffer Objects id (default vertex data)
|
||||||
} Mesh;
|
} Mesh;
|
||||||
|
|
||||||
// Shader type (generic)
|
// Shader
|
||||||
typedef struct Shader {
|
typedef struct Shader {
|
||||||
unsigned int id; // Shader program id
|
unsigned int id; // Shader program id
|
||||||
int *locs; // Shader locations array (MAX_SHADER_LOCATIONS)
|
int *locs; // Shader locations array (MAX_SHADER_LOCATIONS)
|
||||||
} Shader;
|
} Shader;
|
||||||
|
|
||||||
// Material texture map
|
// MaterialMap
|
||||||
typedef struct MaterialMap {
|
typedef struct MaterialMap {
|
||||||
Texture2D texture; // Material map texture
|
Texture2D texture; // Material map texture
|
||||||
Color color; // Material map color
|
Color color; // Material map color
|
||||||
float value; // Material map value
|
float value; // Material map value
|
||||||
} MaterialMap;
|
} MaterialMap;
|
||||||
|
|
||||||
// Material type (generic)
|
// Material, includes shader and maps
|
||||||
typedef struct Material {
|
typedef struct Material {
|
||||||
Shader shader; // Material shader
|
Shader shader; // Material shader
|
||||||
MaterialMap *maps; // Material maps array (MAX_MATERIAL_MAPS)
|
MaterialMap *maps; // Material maps array (MAX_MATERIAL_MAPS)
|
||||||
float params[4]; // Material generic parameters (if required)
|
float params[4]; // Material generic parameters (if required)
|
||||||
} Material;
|
} Material;
|
||||||
|
|
||||||
// Transformation properties
|
// Transform, vectex transformation data
|
||||||
typedef struct Transform {
|
typedef struct Transform {
|
||||||
Vector3 translation; // Translation
|
Vector3 translation; // Translation
|
||||||
Quaternion rotation; // Rotation
|
Quaternion rotation; // Rotation
|
||||||
Vector3 scale; // Scale
|
Vector3 scale; // Scale
|
||||||
} Transform;
|
} Transform;
|
||||||
|
|
||||||
// Bone information
|
// Bone, skeletal animation bone
|
||||||
typedef struct BoneInfo {
|
typedef struct BoneInfo {
|
||||||
char name[32]; // Bone name
|
char name[32]; // Bone name
|
||||||
int parent; // Bone parent
|
int parent; // Bone parent
|
||||||
} BoneInfo;
|
} BoneInfo;
|
||||||
|
|
||||||
// Model type
|
// Model, meshes, materials and animation data
|
||||||
typedef struct Model {
|
typedef struct Model {
|
||||||
Matrix transform; // Local transform matrix
|
Matrix transform; // Local transform matrix
|
||||||
|
|
||||||
|
@ -388,7 +384,7 @@ typedef struct Model {
|
||||||
Transform *bindPose; // Bones base transformation (pose)
|
Transform *bindPose; // Bones base transformation (pose)
|
||||||
} Model;
|
} Model;
|
||||||
|
|
||||||
// Model animation
|
// ModelAnimation
|
||||||
typedef struct ModelAnimation {
|
typedef struct ModelAnimation {
|
||||||
int boneCount; // Number of bones
|
int boneCount; // Number of bones
|
||||||
int frameCount; // Number of animation frames
|
int frameCount; // Number of animation frames
|
||||||
|
@ -396,13 +392,13 @@ typedef struct ModelAnimation {
|
||||||
Transform **framePoses; // Poses array by frame
|
Transform **framePoses; // Poses array by frame
|
||||||
} ModelAnimation;
|
} ModelAnimation;
|
||||||
|
|
||||||
// Ray type (useful for raycast)
|
// Ray, ray for raycasting
|
||||||
typedef struct Ray {
|
typedef struct Ray {
|
||||||
Vector3 position; // Ray position (origin)
|
Vector3 position; // Ray position (origin)
|
||||||
Vector3 direction; // Ray direction
|
Vector3 direction; // Ray direction
|
||||||
} Ray;
|
} Ray;
|
||||||
|
|
||||||
// Raycast hit information
|
// RayCollision, ray hit information
|
||||||
typedef struct RayHitInfo {
|
typedef struct RayHitInfo {
|
||||||
bool hit; // Did the ray hit something?
|
bool hit; // Did the ray hit something?
|
||||||
float distance; // Distance to nearest hit
|
float distance; // Distance to nearest hit
|
||||||
|
@ -410,13 +406,13 @@ typedef struct RayHitInfo {
|
||||||
Vector3 normal; // Surface normal of hit
|
Vector3 normal; // Surface normal of hit
|
||||||
} RayHitInfo;
|
} RayHitInfo;
|
||||||
|
|
||||||
// Bounding box type
|
// BoundingBox
|
||||||
typedef struct BoundingBox {
|
typedef struct BoundingBox {
|
||||||
Vector3 min; // Minimum vertex box-corner
|
Vector3 min; // Minimum vertex box-corner
|
||||||
Vector3 max; // Maximum vertex box-corner
|
Vector3 max; // Maximum vertex box-corner
|
||||||
} BoundingBox;
|
} BoundingBox;
|
||||||
|
|
||||||
// Wave type, defines audio wave data
|
// Wave, audio wave data
|
||||||
typedef struct Wave {
|
typedef struct Wave {
|
||||||
unsigned int sampleCount; // Total number of samples (considering channels!)
|
unsigned int sampleCount; // Total number of samples (considering channels!)
|
||||||
unsigned int sampleRate; // Frequency (samples per second)
|
unsigned int sampleRate; // Frequency (samples per second)
|
||||||
|
@ -427,8 +423,7 @@ typedef struct Wave {
|
||||||
|
|
||||||
typedef struct rAudioBuffer rAudioBuffer;
|
typedef struct rAudioBuffer rAudioBuffer;
|
||||||
|
|
||||||
// Audio stream type
|
// AudioStream, custom audio stream
|
||||||
// NOTE: Useful to create custom audio streams not bound to a specific file
|
|
||||||
typedef struct AudioStream {
|
typedef struct AudioStream {
|
||||||
rAudioBuffer *buffer; // Pointer to internal data used by the audio system
|
rAudioBuffer *buffer; // Pointer to internal data used by the audio system
|
||||||
|
|
||||||
|
@ -437,14 +432,13 @@ typedef struct AudioStream {
|
||||||
unsigned int channels; // Number of channels (1-mono, 2-stereo)
|
unsigned int channels; // Number of channels (1-mono, 2-stereo)
|
||||||
} AudioStream;
|
} AudioStream;
|
||||||
|
|
||||||
// Sound source type
|
// Sound
|
||||||
typedef struct Sound {
|
typedef struct Sound {
|
||||||
AudioStream stream; // Audio stream
|
AudioStream stream; // Audio stream
|
||||||
unsigned int sampleCount; // Total number of samples
|
unsigned int sampleCount; // Total number of samples
|
||||||
} Sound;
|
} Sound;
|
||||||
|
|
||||||
// Music stream type (audio file streaming from memory)
|
// Music, audio stream, anything longer than ~10 seconds should be streamed
|
||||||
// NOTE: Anything longer than ~10 seconds should be streamed
|
|
||||||
typedef struct Music {
|
typedef struct Music {
|
||||||
AudioStream stream; // Audio stream
|
AudioStream stream; // Audio stream
|
||||||
unsigned int sampleCount; // Total number of samples
|
unsigned int sampleCount; // Total number of samples
|
||||||
|
@ -454,7 +448,7 @@ typedef struct Music {
|
||||||
void *ctxData; // Audio context data, depends on type
|
void *ctxData; // Audio context data, depends on type
|
||||||
} Music;
|
} Music;
|
||||||
|
|
||||||
// Head-Mounted-Display device parameters
|
// VrDeviceInfo, Head-Mounted-Display device parameters
|
||||||
typedef struct VrDeviceInfo {
|
typedef struct VrDeviceInfo {
|
||||||
int hResolution; // Horizontal resolution in pixels
|
int hResolution; // Horizontal resolution in pixels
|
||||||
int vResolution; // Vertical resolution in pixels
|
int vResolution; // Vertical resolution in pixels
|
||||||
|
@ -468,7 +462,7 @@ typedef struct VrDeviceInfo {
|
||||||
float chromaAbCorrection[4]; // Chromatic aberration correction parameters
|
float chromaAbCorrection[4]; // Chromatic aberration correction parameters
|
||||||
} VrDeviceInfo;
|
} VrDeviceInfo;
|
||||||
|
|
||||||
// VR Stereo rendering configuration for simulator
|
// VrStereoConfig, VR stereo rendering configuration for simulator
|
||||||
typedef struct VrStereoConfig {
|
typedef struct VrStereoConfig {
|
||||||
Matrix projection[2]; // VR projection matrices (per eye)
|
Matrix projection[2]; // VR projection matrices (per eye)
|
||||||
Matrix viewOffset[2]; // VR view offset matrices (per eye)
|
Matrix viewOffset[2]; // VR view offset matrices (per eye)
|
||||||
|
@ -1045,7 +1039,7 @@ RLAPI bool SaveFileText(const char *fileName, char *text); // Save text d
|
||||||
RLAPI bool FileExists(const char *fileName); // Check if file exists
|
RLAPI bool FileExists(const char *fileName); // Check if file exists
|
||||||
RLAPI bool DirectoryExists(const char *dirPath); // Check if a directory path exists
|
RLAPI bool DirectoryExists(const char *dirPath); // Check if a directory path exists
|
||||||
RLAPI bool IsFileExtension(const char *fileName, const char *ext);// Check file extension (including point: .png, .wav)
|
RLAPI bool IsFileExtension(const char *fileName, const char *ext);// Check file extension (including point: .png, .wav)
|
||||||
RLAPI const char *GetFileExtension(const char *fileName); // Get pointer to extension for a filename string (includes dot: ".png")
|
RLAPI const char *GetFileExtension(const char *fileName); // Get pointer to extension for a filename string (includes dot: '.png')
|
||||||
RLAPI const char *GetFileName(const char *filePath); // Get pointer to filename for a path string
|
RLAPI const char *GetFileName(const char *filePath); // Get pointer to filename for a path string
|
||||||
RLAPI const char *GetFileNameWithoutExt(const char *filePath); // Get filename string without extension (uses static string)
|
RLAPI const char *GetFileNameWithoutExt(const char *filePath); // Get filename string without extension (uses static string)
|
||||||
RLAPI const char *GetDirectoryPath(const char *filePath); // Get full path for a given fileName with path (uses static string)
|
RLAPI const char *GetDirectoryPath(const char *filePath); // Get full path for a given fileName with path (uses static string)
|
||||||
|
@ -1202,7 +1196,7 @@ RLAPI Rectangle GetCollisionRec(Rectangle rec1, Rectangle rec2);
|
||||||
RLAPI Image LoadImage(const char *fileName); // Load image from file into CPU memory (RAM)
|
RLAPI Image LoadImage(const char *fileName); // Load image from file into CPU memory (RAM)
|
||||||
RLAPI Image LoadImageRaw(const char *fileName, int width, int height, int format, int headerSize); // Load image from RAW file data
|
RLAPI Image LoadImageRaw(const char *fileName, int width, int height, int format, int headerSize); // Load image from RAW file data
|
||||||
RLAPI Image LoadImageAnim(const char *fileName, int *frames); // Load image sequence from file (frames appended to image.data)
|
RLAPI Image LoadImageAnim(const char *fileName, int *frames); // Load image sequence from file (frames appended to image.data)
|
||||||
RLAPI Image LoadImageFromMemory(const char *fileType, const unsigned char *fileData, int dataSize); // Load image from memory buffer, fileType refers to extension: i.e. ".png"
|
RLAPI Image LoadImageFromMemory(const char *fileType, const unsigned char *fileData, int dataSize); // Load image from memory buffer, fileType refers to extension: i.e. '.png'
|
||||||
RLAPI void UnloadImage(Image image); // Unload image from CPU memory (RAM)
|
RLAPI void UnloadImage(Image image); // Unload image from CPU memory (RAM)
|
||||||
RLAPI bool ExportImage(Image image, const char *fileName); // Export image data to file, returns true on success
|
RLAPI bool ExportImage(Image image, const char *fileName); // Export image data to file, returns true on success
|
||||||
RLAPI bool ExportImageAsCode(Image image, const char *fileName); // Export image as code file defining an array of bytes, returns true on success
|
RLAPI bool ExportImageAsCode(Image image, const char *fileName); // Export image as code file defining an array of bytes, returns true on success
|
||||||
|
@ -1319,7 +1313,7 @@ RLAPI Font GetFontDefault(void);
|
||||||
RLAPI Font LoadFont(const char *fileName); // Load font from file into GPU memory (VRAM)
|
RLAPI Font LoadFont(const char *fileName); // Load font from file into GPU memory (VRAM)
|
||||||
RLAPI Font LoadFontEx(const char *fileName, int fontSize, int *fontChars, int charsCount); // Load font from file with extended parameters
|
RLAPI Font LoadFontEx(const char *fileName, int fontSize, int *fontChars, int charsCount); // Load font from file with extended parameters
|
||||||
RLAPI Font LoadFontFromImage(Image image, Color key, int firstChar); // Load font from Image (XNA style)
|
RLAPI Font LoadFontFromImage(Image image, Color key, int firstChar); // Load font from Image (XNA style)
|
||||||
RLAPI Font LoadFontFromMemory(const char *fileType, const unsigned char *fileData, int dataSize, int fontSize, int *fontChars, int charsCount); // Load font from memory buffer, fileType refers to extension: i.e. ".ttf"
|
RLAPI Font LoadFontFromMemory(const char *fileType, const unsigned char *fileData, int dataSize, int fontSize, int *fontChars, int charsCount); // Load font from memory buffer, fileType refers to extension: i.e. '.ttf'
|
||||||
RLAPI CharInfo *LoadFontData(const unsigned char *fileData, int dataSize, int fontSize, int *fontChars, int charsCount, int type); // Load font data for further use
|
RLAPI CharInfo *LoadFontData(const unsigned char *fileData, int dataSize, int fontSize, int *fontChars, int charsCount, int type); // Load font data for further use
|
||||||
RLAPI Image GenImageFontAtlas(const CharInfo *chars, Rectangle **recs, int charsCount, int fontSize, int padding, int packMethod); // Generate image font atlas using chars info
|
RLAPI Image GenImageFontAtlas(const CharInfo *chars, Rectangle **recs, int charsCount, int fontSize, int padding, int packMethod); // Generate image font atlas using chars info
|
||||||
RLAPI void UnloadFontData(CharInfo *chars, int charsCount); // Unload font chars info data (RAM)
|
RLAPI void UnloadFontData(CharInfo *chars, int charsCount); // Unload font chars info data (RAM)
|
||||||
|
@ -1470,7 +1464,7 @@ RLAPI void SetMasterVolume(float volume); // Set mas
|
||||||
|
|
||||||
// Wave/Sound loading/unloading functions
|
// Wave/Sound loading/unloading functions
|
||||||
RLAPI Wave LoadWave(const char *fileName); // Load wave data from file
|
RLAPI Wave LoadWave(const char *fileName); // Load wave data from file
|
||||||
RLAPI Wave LoadWaveFromMemory(const char *fileType, const unsigned char *fileData, int dataSize); // Load wave from memory buffer, fileType refers to extension: i.e. ".wav"
|
RLAPI Wave LoadWaveFromMemory(const char *fileType, const unsigned char *fileData, int dataSize); // Load wave from memory buffer, fileType refers to extension: i.e. '.wav'
|
||||||
RLAPI Sound LoadSound(const char *fileName); // Load sound from file
|
RLAPI Sound LoadSound(const char *fileName); // Load sound from file
|
||||||
RLAPI Sound LoadSoundFromWave(Wave wave); // Load sound from wave data
|
RLAPI Sound LoadSoundFromWave(Wave wave); // Load sound from wave data
|
||||||
RLAPI void UpdateSound(Sound sound, const void *data, int samplesCount);// Update sound buffer with new data
|
RLAPI void UpdateSound(Sound sound, const void *data, int samplesCount);// Update sound buffer with new data
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue