Add shader_platform.h for platform-specific includes.
This commit is contained in:
parent
7411df6c73
commit
dda4758df6
@ -459,7 +459,7 @@ if test $ac_cv_my_sar_int8 = yes && \
|
||||
CFLAGS="$CFLAGS -DRIGHTSHIFT_IS_SAR"
|
||||
fi
|
||||
|
||||
CFLAGS="$CFLAGS -DUNZIP_SUPPORT -DSPC700_C -I. -I.. $ZIP_CFLAGS"
|
||||
CFLAGS="$CFLAGS -DUNZIP_SUPPORT -DSNES9X_GTK -DSPC700_C -I. -I.. $ZIP_CFLAGS"
|
||||
|
||||
CXXFLAGS="$CFLAGS"
|
||||
|
||||
|
@ -192,7 +192,7 @@
|
||||
#ifndef CGGLCG_H
|
||||
#define CGGLCG_H
|
||||
|
||||
#include <epoxy/gl.h>
|
||||
#include "shader_platform.h"
|
||||
|
||||
#include "CCGShader.h"
|
||||
#include "cgFunctions.h"
|
||||
|
@ -193,7 +193,7 @@
|
||||
#include "cgFunctions.h"
|
||||
#include <dlfcn.h>
|
||||
#include <stdio.h>
|
||||
#include <epoxy/gl.h>
|
||||
#include "shader_platform.h"
|
||||
|
||||
void* hCgDll = NULL;
|
||||
void* hCgGLDll = NULL;
|
||||
|
@ -199,7 +199,7 @@
|
||||
#define CGD3D9DLL_API
|
||||
#define CGGL_API
|
||||
|
||||
#include <epoxy/gl.h>
|
||||
#include "shader_platform.h"
|
||||
|
||||
#define CG_API
|
||||
typedef struct _CGprogram* CGprogram;
|
||||
|
@ -1,7 +1,6 @@
|
||||
#include "glsl.h"
|
||||
#include "../../conffile.h"
|
||||
#include "shader_helpers.h"
|
||||
#include "../gtk_s9x.h"
|
||||
|
||||
static const GLfloat tex_coords[16] = { 0.0f, 0.0f, 1.0f, 0.0f, 1.0f, 1.0f, 0.0f, 1.0f,
|
||||
0.0f, 1.0f, 1.0f, 1.0f, 1.0f, 0.0f, 0.0f, 0.0f };
|
||||
@ -516,7 +515,10 @@ bool GLSLShader::load_shader (char *filename)
|
||||
if (value)
|
||||
{
|
||||
param[i].val = atof (value);
|
||||
param[i].val = CLAMP (param[i].val, param[i].min, param[i].max);
|
||||
if (param[i].val < param[i].min)
|
||||
param[i].val = param[i].min;
|
||||
if (param[i].val > param[i].max)
|
||||
param[i].val = param[i].max;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1,8 +1,8 @@
|
||||
#include <vector>
|
||||
#include <deque>
|
||||
#include <limits.h>
|
||||
#include <epoxy/gl.h>
|
||||
#include "../../conffile.h"
|
||||
#include "shader_platform.h"
|
||||
|
||||
static const unsigned int glsl_max_passes = 20;
|
||||
|
||||
|
@ -1,9 +1,9 @@
|
||||
#include <epoxy/gl.h>
|
||||
#include <png.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
#include "shader_helpers.h"
|
||||
#include "shader_platform.h"
|
||||
|
||||
static void gl_error_callback( GLenum source,
|
||||
GLenum type,
|
||||
|
@ -1,7 +1,7 @@
|
||||
#ifndef __SHADER_HELPERS_H
|
||||
#define __SHADER_HELPERS_H
|
||||
|
||||
#include <epoxy/gl.h>
|
||||
#include "shader_platform.h"
|
||||
|
||||
typedef struct _STGA
|
||||
{
|
||||
|
9
gtk/src/shaders/shader_platform.h
Normal file
9
gtk/src/shaders/shader_platform.h
Normal file
@ -0,0 +1,9 @@
|
||||
#ifndef __SHADER_PLATFORM_H
|
||||
#define __SHADER_PLATFORM_H
|
||||
|
||||
#ifdef SNES9X_GTK
|
||||
#include <epoxy/gl.h>
|
||||
#include <epoxy/glx.h>
|
||||
#endif
|
||||
|
||||
#endif /* __SHADER_PLATFORM_H */
|
Loading…
Reference in New Issue
Block a user