Commit Graph

67 Commits

Author SHA1 Message Date
Jonas Kulla 26843f2e51 Implement FPS display (F2 to toggle ON/OFF) 2013-10-06 07:05:01 +02:00
Jonas Kulla 20ec560145 Wrap color clear in 'FBO::clear()' convenience function 2013-10-01 13:10:14 +02:00
Jonas Kulla 307eeb732d Factor out performance timers into separate files
This should make graphics.cpp somewhat easier to navigate/read.
GL_EXT_timer_query is also made optional, and if it's not present
dummy functions will be called instead.
2013-09-27 16:54:01 +02:00
Jonas Kulla 92525cd077 Make this mess of performance measuring a bit more readable 2013-09-27 04:47:12 +02:00
Jonas Kulla fe557bca1d Implement "show_cursor" attribute in Graphics module
If false (the default), the system cursor is hidden
inside the game window.
2013-09-24 22:56:25 +02:00
Jonas Kulla a327d4c324 Fix valgrind warning (value might be uninitialized) 2013-09-24 19:56:36 +02:00
Jonas Kulla b85988d194 Fix typo 2013-09-23 11:18:20 +02:00
Jonas Kulla da4e0fbed0 Implement smooth scaling 2013-09-23 11:00:50 +02:00
Jonas Kulla f00136c489 Implement fixed aspect ratio 2013-09-23 10:39:16 +02:00
Jonas Kulla 9e63fb6b64 Remove the remaining bits of deprecated GL usage
The drawing is now completely shader based, which makes away
with all usage of the depracted matrix stack. This also allows
us to do things like simple translations and texture coordinate
translation directly instead of doing everything indirectly
through matrices.

Fixed vertex attributes ('vertexPointer()' etc) are also
replaced with user defined attribute arrays.
2013-09-23 07:50:22 +02:00
Jonas Kulla 6c7d751dbd Remove 'Default' FBO binding (only allow 'Read' and 'Draw')
Also make code more verbose by removing default mode
parameter value to 'FBO::bind'
2013-09-06 14:56:30 +02:00
Jonas Kulla b151a22f6e Rename 'Tex' to 'TEX' for consistency 2013-09-06 12:26:41 +02:00
Jonas Kulla 55596e9da9 Rename 'RB'(renderbuffer) to 'RBO'(renderbuffer object) 2013-09-06 12:16:24 +02:00
Jonas Kulla 0253b6ed2b Use C99 integer types instead of Qt's 2013-09-04 13:30:14 +02:00
Jonas Kulla 84db116d0c Rename 'bound' to 'clamp' 2013-09-03 15:31:29 +02:00
Jonas Kulla 8674cb8e06 Always glClear before blitting to screen
Prevents a distorted screen when an error happens during
script loading (ie. before the first drawn frame) and fullscreen
is turned on in the config.
This will also be necessarry once fixed aspect ratio is implemented.
2013-09-02 17:31:34 +02:00
Jonas Kulla ff25887f41 Initial commit 2013-09-01 16:27:21 +02:00