Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
SRB2
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
STJr
SRB2
Commits
d056e82b
Commit
d056e82b
authored
Nov 14, 2014
by
Ronald Kinard
Browse files
Options
Downloads
Patches
Plain Diff
Parse GL version correctly.
parent
d8484a86
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/hardware/r_opengl/r_opengl.c
+5
-5
5 additions, 5 deletions
src/hardware/r_opengl/r_opengl.c
with
5 additions
and
5 deletions
src/hardware/r_opengl/r_opengl.c
+
5
−
5
View file @
d056e82b
...
@@ -535,7 +535,7 @@ boolean SetupGLFunc13(void)
...
@@ -535,7 +535,7 @@ boolean SetupGLFunc13(void)
// Parse the GL version
// Parse the GL version
if
(
version
!=
NULL
)
if
(
version
!=
NULL
)
{
{
if
(
sscanf
(
version
,
"%d.%d"
,
&
glmajor
,
&
glminor
)
==
2
)
if
(
sscanf
(
(
const
char
*
)
version
,
"%d.%d"
,
&
glmajor
,
&
glminor
)
==
2
)
{
{
// Look, we gotta prepare for the inevitable arrival of GL 2.0 code...
// Look, we gotta prepare for the inevitable arrival of GL 2.0 code...
switch
(
glmajor
)
switch
(
glmajor
)
...
@@ -543,6 +543,10 @@ boolean SetupGLFunc13(void)
...
@@ -543,6 +543,10 @@ boolean SetupGLFunc13(void)
case
1
:
case
1
:
if
(
glminor
==
3
)
gl13
=
true
;
if
(
glminor
==
3
)
gl13
=
true
;
break
;
break
;
case
2
:
case
3
:
case
4
:
gl13
=
true
;
default:
default:
break
;
break
;
}
}
...
@@ -2400,12 +2404,8 @@ EXPORT void HWRAPI(MakeScreenFinalTexture) (void)
...
@@ -2400,12 +2404,8 @@ EXPORT void HWRAPI(MakeScreenFinalTexture) (void)
EXPORT
void
HWRAPI
(
DrawScreenFinalTexture
)(
int
width
,
int
height
)
EXPORT
void
HWRAPI
(
DrawScreenFinalTexture
)(
int
width
,
int
height
)
{
{
float
xfix
,
yfix
;
float
xfix
,
yfix
;
int
lmaxx
,
lmaxy
;
INT32
texsize
=
2048
;
INT32
texsize
=
2048
;
lmaxx
=
width
<
screen_width
?
screen_width
:
width
;
lmaxy
=
height
<
screen_height
?
screen_height
:
height
;
if
(
screen_width
<=
1024
)
if
(
screen_width
<=
1024
)
texsize
=
1024
;
texsize
=
1024
;
if
(
screen_width
<=
512
)
if
(
screen_width
<=
512
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment