Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Libretro
Craft
Commits
2c6c6cfd
Commit
2c6c6cfd
authored
Aug 07, 2017
by
Libretro-Admin
Committed by
GitHub
Aug 07, 2017
Browse files
Merge pull request #14 from bparker06/mem
correct memory and GL errors, fixes
#7
parents
6c2f07fe
e21dd50c
Changes
4
Hide whitespace changes
Inline
Side-by-side
Makefile.libretro
View file @
2c6c6cfd
...
...
@@ -397,6 +397,12 @@ CFLAGS += -DINLINE="inline"
CXXFLAGS
+=
-DINLINE
=
"inline"
endif
ifneq
($(SANITIZER),)
CFLAGS
:=
-fsanitize
=
$(SANITIZER)
$(CFLAGS)
CXXFLAGS
:=
-fsanitize
=
$(SANITIZER)
$(CXXFLAGS)
LDFLAGS
:=
-fsanitize
=
$(SANITIZER)
$(LDFLAGS)
endif
ifeq
($(DEBUG), 1)
CPUOPTS
+=
-O0
-g
CPUOPTS
+=
-DOPENGL_DEBUG
...
...
libretro/libretro.c
View file @
2c6c6cfd
...
...
@@ -40,7 +40,7 @@ static void fallback_log(enum retro_log_level level, const char *fmt, ...)
#if defined(HAVE_OPENGL) || defined(HAVE_OPENGLES)
static
bool
fb_ready
=
false
;
static
bool
init_program_now
=
fals
e
;
static
bool
init_program_now
=
tru
e
;
static
void
context_reset
(
void
)
{
...
...
src/main.c
View file @
2c6c6cfd
...
...
@@ -467,7 +467,7 @@ static uintptr_t gen_wireframe_buffer(float x, float y, float z, float n)
static
uintptr_t
gen_water_buffer
(
float
x
,
float
y
,
float
z
,
float
n
)
{
float
data
[
10
8
];
float
data
[
1
2
0
];
float
ao
[
6
][
4
]
=
{
0
};
float
light
[
6
][
4
]
=
{
{
0
.
5
,
0
.
5
,
0
.
5
,
0
.
5
},
...
...
@@ -483,7 +483,7 @@ static uintptr_t gen_water_buffer(float x, float y, float z, float n)
0
,
0
,
255
,
0
,
0
,
0
,
x
,
y
-
n
,
z
,
n
);
make_cube_faces
(
data
+
54
,
ao
,
light
,
data
+
60
,
ao
,
light
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
0
,
0
,
255
,
0
,
0
,
x
,
y
+
n
,
z
,
n
);
...
...
@@ -2668,7 +2668,7 @@ static void main_set_db_path(void)
const
char
*
dir
=
NULL
;
Model
*
g
=
(
Model
*
)
&
model
;
if
(
environ_cb
(
RETRO_ENVIRONMENT_GET_SYSTEM_DIRECTORY
,
&
dir
)
&&
dir
)
if
(
environ_cb
(
RETRO_ENVIRONMENT_GET_SYSTEM_DIRECTORY
,
&
dir
)
&&
dir
&&
*
dir
)
{
#ifdef _WIN32
char
slash
=
'\\'
;
...
...
src/renderer.c
View file @
2c6c6cfd
...
...
@@ -433,7 +433,7 @@ void render_shader_program(struct shader_program_info *info)
glUniform1f
(
info
->
attrib
->
extra3
,
info
->
extra3
.
data
);
if
(
info
->
extra4
.
enable
)
glUniform1
f
(
info
->
attrib
->
extra4
,
info
->
extra4
.
data
);
glUniform1
i
(
info
->
attrib
->
extra4
,
info
->
extra4
.
data
);
if
(
info
->
timer
.
enable
)
glUniform1f
(
info
->
attrib
->
timer
,
info
->
timer
.
data
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment