aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorraysan5 <raysan5@gmail.com>2015-08-28 14:14:29 +0200
committerraysan5 <raysan5@gmail.com>2015-08-28 14:14:29 +0200
commitc52ba520cec3c9d3fdf7cb1f70da95e9396c59a9 (patch)
treed3b6d5d422a9b2bbb40711690d2fb39e51e2592f /src
parent322ca97c24f214d665cad512a70a696b489ecb52 (diff)
downloadraylib-c52ba520cec3c9d3fdf7cb1f70da95e9396c59a9.tar.gz
raylib-c52ba520cec3c9d3fdf7cb1f70da95e9396c59a9.zip
Small tweaks
Diffstat (limited to 'src')
-rw-r--r--src/core.c4
-rw-r--r--src/raylib.h11
-rw-r--r--src/rlgl.c2
-rw-r--r--src/text.c8
4 files changed, 16 insertions, 9 deletions
diff --git a/src/core.c b/src/core.c
index e3c4e10b..8d832fd2 100644
--- a/src/core.c
+++ b/src/core.c
@@ -1007,8 +1007,8 @@ static void InitDisplay(int width, int height)
glfwWindowHint(GLFW_RESIZABLE, GL_FALSE); // Avoid window being resizable
//glfwWindowHint(GLFW_DECORATED, GL_TRUE); // Border and buttons on Window
- //glfwWindowHint(GLFW_RED_BITS, 8); // Color framebuffer red component bits
- //glfwWindowHint(GLFW_DEPTH_BITS, 16); // Depth buffer bits (24 by default)
+ //glfwWindowHint(GLFW_RED_BITS, 8); // Framebuffer red color component bits
+ //glfwWindowHint(GLFW_DEPTH_BITS, 16); // Depthbuffer bits (24 by default)
//glfwWindowHint(GLFW_REFRESH_RATE, 0); // Refresh rate for fullscreen window
//glfwWindowHint(GLFW_CLIENT_API, GLFW_OPENGL_API); // Default OpenGL API to use. Alternative: GLFW_OPENGL_ES_API
//glfwWindowHint(GLFW_AUX_BUFFERS, 0); // Number of auxiliar buffers
diff --git a/src/raylib.h b/src/raylib.h
index f5220e2e..5ceb3fc1 100644
--- a/src/raylib.h
+++ b/src/raylib.h
@@ -517,18 +517,19 @@ float GetGesturePinchAngle(void); // Get gesture pinch ang
// Camera System Functions (Module: camera)
//------------------------------------------------------------------------------------
void SetCameraMode(int mode); // Set camera mode (multiple camera modes available)
-Camera UpdateCamera(Vector3 *playerPosition); // Update camera and player position (1st person and 3rd person cameras)
+Camera UpdateCamera(Vector3 *position); // Update camera and player position (1st person and 3rd person cameras)
-void SetCameraMoveControls(int frontKey, int backKey,
- int leftKey, int rightKey,
- int upKey, int downKey); // Set camera move controls (1st person and 3rd person cameras)
+void SetCameraPosition(Vector3 position); // Set internal camera position
+void SetCameraTarget(Vector3 target); // Set internal camera target
void SetCameraPanControl(int panKey); // Set camera pan key to combine with mouse movement (free camera)
void SetCameraAltControl(int altKey); // Set camera alt key to combine with mouse movement (free camera)
void SetCameraSmoothZoomControl(int szKey); // Set camera smooth zoom key to combine with mouse (free camera)
+void SetCameraMoveControls(int frontKey, int backKey,
+ int leftKey, int rightKey,
+ int upKey, int downKey); // Set camera move controls (1st person and 3rd person cameras)
void SetCameraMouseSensitivity(float sensitivity); // Set camera mouse sensitivity (1st person and 3rd person cameras)
-void SetCameraTarget(Vector3 target); // Set internal camera target
//------------------------------------------------------------------------------------
// Basic Shapes Drawing Functions (Module: shapes)
diff --git a/src/rlgl.c b/src/rlgl.c
index 163fa35a..6dea10c0 100644
--- a/src/rlgl.c
+++ b/src/rlgl.c
@@ -858,7 +858,7 @@ void rlglInit(void)
// NOTE: We don't need that much data on screen... right now...
#if defined(GRAPHICS_API_OPENGL_11)
- TraceLog(INFO, "OpenGL 1.1 profile initialized");
+ //TraceLog(INFO, "OpenGL 1.1 (or driver default) profile initialized");
#endif
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
diff --git a/src/text.c b/src/text.c
index 65d52f26..3d866c86 100644
--- a/src/text.c
+++ b/src/text.c
@@ -614,8 +614,14 @@ static SpriteFont LoadRBMF(const char *fileName)
}
// Generate a sprite font from TTF data (font size required)
+// NOTE: This function is a mess, it should be completely redone!
static SpriteFont LoadTTF(const char *fileName, int fontSize)
{
+ // Steps:
+
+ // 1) Generate sprite sheet image with characters from TTF
+ // 2) Load image as SpriteFont
+
SpriteFont font;
Image image;
@@ -631,7 +637,7 @@ static SpriteFont LoadTTF(const char *fileName, int fontSize)
unsigned char *tempBitmap = (unsigned char *)malloc(image.width*image.height*sizeof(unsigned char)); // One channel bitmap returned!
- // REFERENCE
+ // Reference struct
/*
typedef struct
{