Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
libSDL
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
PocketInsanity
libSDL
Commits
a429b886
Commit
a429b886
authored
Feb 09, 2011
by
Sam Lantinga
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed crash when shaders are not supported
parent
631784d9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
3 deletions
+7
-3
testshader.c
test/testshader.c
+7
-3
No files found.
test/testshader.c
View file @
a429b886
...
@@ -181,9 +181,11 @@ static SDL_bool CompileShaderProgram(ShaderData *data)
...
@@ -181,9 +181,11 @@ static SDL_bool CompileShaderProgram(ShaderData *data)
static
void
DestroyShaderProgram
(
ShaderData
*
data
)
static
void
DestroyShaderProgram
(
ShaderData
*
data
)
{
{
glDeleteObjectARB
(
data
->
vert_shader
);
if
(
shaders_supported
)
{
glDeleteObjectARB
(
data
->
frag_shader
);
glDeleteObjectARB
(
data
->
vert_shader
);
glDeleteObjectARB
(
data
->
program
);
glDeleteObjectARB
(
data
->
frag_shader
);
glDeleteObjectARB
(
data
->
program
);
}
}
}
static
SDL_bool
InitShaders
()
static
SDL_bool
InitShaders
()
...
@@ -481,3 +483,5 @@ main(int argc, char *argv[])
...
@@ -481,3 +483,5 @@ main(int argc, char *argv[])
}
}
#endif
/* HAVE_OPENGL */
#endif
/* HAVE_OPENGL */
/* vi: set ts=4 sw=4 expandtab: */
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