Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
PoroCYon
Bonzomatic
Commits
603fe3a1
Commit
603fe3a1
authored
Apr 05, 2018
by
PoroCYon
Committed by
Gargaj
Apr 05, 2018
Browse files
Print an error if OpenGL 4.1 isn't supported (cf #56) (#57)
* Print an error if OpenGL 4.1 isn't supported (cf #56) * fix typo
parent
7ba8d8a3
Changes
2
Hide whitespace changes
Inline
Side-by-side
README.md
View file @
603fe3a1
...
...
@@ -16,8 +16,13 @@ The tool was originally conceived and implemented after the Revision 2014 demosc
-
F11 or Ctrl/Cmd-f: hide shader overlay
-
Alt-F4 or Shift+Escape: exbobolate your planet
## Requirements
On Windows, both DirectX 9 and 11 are supported.
For the OpenGL version (for any platform), at least OpenGL 4.1 is required.
## Configuration
Create a
``
`config.json`
``
with e.g. the following contents: (all fields are optional)
Create a
`config.json`
with e.g. the following contents: (all fields are optional)
```
javascript
{
"
window
"
:{
/* default window size / state, if there's a setup dialog, it will override it */
...
...
src/platform_glfw/Renderer.cpp
View file @
603fe3a1
...
...
@@ -188,6 +188,14 @@ namespace Renderer
GLuint
pbo
[
2
];
static
void
error_callback
(
int
error
,
const
char
*
description
)
{
switch
(
error
)
{
case
GLFW_API_UNAVAILABLE
:
printf
(
"OpenGL is unavailable: "
);
break
;
case
GLFW_VERSION_UNAVAILABLE
:
printf
(
"OpenGL 4.1 (the minimum requirement) is not available: "
);
break
;
}
printf
(
"%s
\n
"
,
description
);
}
void
key_callback
(
GLFWwindow
*
window
,
int
key
,
int
scancode
,
int
action
,
int
mods
);
...
...
Write
Preview
Supports
Markdown
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