mirror of
https://github.com/libretro/RetroArch.git
synced 2024-11-23 16:09:47 +00:00
Move all font stuff to gfx/fonts.
Rename stuff so griffin doesn't break.
This commit is contained in:
parent
78e5d47a9b
commit
beca1c44f3
2
Makefile
2
Makefile
@ -162,7 +162,7 @@ ifeq ($(HAVE_SDL), 1)
|
||||
endif
|
||||
|
||||
ifeq ($(HAVE_OPENGL), 1)
|
||||
OBJ += gfx/gl.o gfx/gfx_context.o gfx/gl_font.o gfx/fonts/gl_raster_font.o gfx/math/matrix.o
|
||||
OBJ += gfx/gl.o gfx/gfx_context.o gfx/fonts/gl_font.o gfx/fonts/gl_raster_font.o gfx/math/matrix.o
|
||||
|
||||
ifeq ($(HAVE_KMS), 1)
|
||||
OBJ += gfx/context/drm_egl_ctx.o
|
||||
|
@ -102,7 +102,7 @@ ifeq ($(HAVE_THREADS), 1)
|
||||
endif
|
||||
|
||||
ifeq ($(HAVE_OPENGL), 1)
|
||||
OBJ += gfx/gl.o gfx/math/matrix.o gfx/gl_font.o gfx/fonts/gl_raster_font.o gfx/gfx_context.o gfx/context/wgl_ctx.o
|
||||
OBJ += gfx/gl.o gfx/math/matrix.o gfx/fonts/gl_font.o gfx/fonts/gl_raster_font.o gfx/gfx_context.o gfx/context/wgl_ctx.o
|
||||
DEFINES += -DHAVE_OPENGL
|
||||
LIBS += -lopengl32 -lgdi32
|
||||
endif
|
||||
|
@ -20,7 +20,7 @@
|
||||
#include "../../config.h"
|
||||
#endif
|
||||
|
||||
static const font_renderer_driver_t *backends[] = {
|
||||
static const font_renderer_driver_t *font_backends[] = {
|
||||
#ifdef HAVE_FREETYPE
|
||||
&ft_font_renderer,
|
||||
#endif
|
||||
@ -32,24 +32,24 @@ static const font_renderer_driver_t *backends[] = {
|
||||
|
||||
bool font_renderer_create_default(const font_renderer_driver_t **driver, void **handle)
|
||||
{
|
||||
for (unsigned i = 0; i < ARRAY_SIZE(backends); i++)
|
||||
for (unsigned i = 0; i < ARRAY_SIZE(font_backends); i++)
|
||||
{
|
||||
const char *font_path = *g_settings.video.font_path ? g_settings.video.font_path : NULL;
|
||||
if (!font_path)
|
||||
font_path = backends[i]->get_default_font();
|
||||
font_path = font_backends[i]->get_default_font();
|
||||
|
||||
if (!font_path)
|
||||
continue;
|
||||
|
||||
*handle = backends[i]->init(font_path, g_settings.video.font_size);
|
||||
*handle = font_backends[i]->init(font_path, g_settings.video.font_size);
|
||||
if (*handle)
|
||||
{
|
||||
RARCH_LOG("Using font rendering backend: %s.\n", backends[i]->ident);
|
||||
*driver = backends[i];
|
||||
RARCH_LOG("Using font rendering backend: %s.\n", font_backends[i]->ident);
|
||||
*driver = font_backends[i];
|
||||
return true;
|
||||
}
|
||||
else
|
||||
RARCH_ERR("Failed to create rendering backend: %s.\n", backends[i]->ident);
|
||||
RARCH_ERR("Failed to create rendering backend: %s.\n", font_backends[i]->ident);
|
||||
}
|
||||
|
||||
*driver = NULL;
|
||||
|
@ -14,18 +14,18 @@
|
||||
*/
|
||||
|
||||
#include "gl_font.h"
|
||||
#include "../general.h"
|
||||
#include "../../general.h"
|
||||
|
||||
static const gl_font_renderer_t *backends[] = {
|
||||
static const gl_font_renderer_t *gl_font_backends[] = {
|
||||
&gl_raster_font,
|
||||
};
|
||||
|
||||
const gl_font_renderer_t *gl_font_init_first(void *data, const char *font_path, unsigned font_size)
|
||||
{
|
||||
for (unsigned i = 0; i < ARRAY_SIZE(backends); i++)
|
||||
for (unsigned i = 0; i < ARRAY_SIZE(gl_font_backends); i++)
|
||||
{
|
||||
if (backends[i]->init(data, font_path, font_size))
|
||||
return backends[i];
|
||||
if (gl_font_backends[i]->init(data, font_path, font_size))
|
||||
return gl_font_backends[i];
|
||||
}
|
||||
|
||||
return NULL;
|
@ -17,7 +17,7 @@
|
||||
#define GL_FONT_H__
|
||||
|
||||
#include <stdint.h>
|
||||
#include "../boolean.h"
|
||||
#include "../../boolean.h"
|
||||
|
||||
typedef struct gl_font_renderer
|
||||
{
|
1
gfx/gl.c
1
gfx/gl.c
@ -34,7 +34,6 @@
|
||||
#endif
|
||||
|
||||
#include "gl_common.h"
|
||||
#include "gl_font.h"
|
||||
#include "gfx_common.h"
|
||||
#include "gfx_context.h"
|
||||
#include "../compat/strl.h"
|
||||
|
@ -21,7 +21,7 @@
|
||||
#include "math/matrix.h"
|
||||
#include "gfx_context.h"
|
||||
#include "scaler/scaler.h"
|
||||
#include "gl_font.h"
|
||||
#include "fonts/gl_font.h"
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "../config.h"
|
||||
|
Loading…
Reference in New Issue
Block a user