Jonas Kulla
8b53681e11
Turn on 'fixedAspectRatio' by default
...
This is more consistent with RMXP's behavior.
2013-10-09 14:17:21 +02:00
Jonas Kulla
f8e8ece946
Forgot to add license header
2013-10-09 13:44:15 +02:00
Jonas Kulla
cb6f73f7df
Rename 'GlobalState' to 'SharedState' to avoid confusion with GLState
...
This was particularly nasty with the shorthand macros
'gState' and 'glState'. The former is now 'shState'.
2013-10-09 12:30:33 +02:00
Jonas Kulla
807bee5748
Print info about shader compilation to console
2013-10-09 12:26:42 +02:00
Jonas Kulla
ba304feb54
Minor code move
...
Move animation based state data together and add comments
2013-10-09 11:52:39 +02:00
Jonas Kulla
34d4103111
Always request OpenGL Core profile
2013-10-08 06:29:05 +02:00
Jonas Kulla
dd25323cdd
Ifdef out more RGSS2 functionality
2013-10-06 10:28:03 +02:00
Jonas Kulla
49e7b66a53
Bitmap: s/tex/gl
2013-10-06 08:54:16 +02:00
Jonas Kulla
89238aebe9
s/rgss/RGSS
2013-10-06 07:11:03 +02:00
Jonas Kulla
26843f2e51
Implement FPS display (F2 to toggle ON/OFF)
2013-10-06 07:05:01 +02:00
Jonas Kulla
41675859dd
Actually destroy duplicated PHYSFS_Io instance on close
...
Fixes crash after loading about a hundred maps
2013-10-06 05:11:22 +02:00
Jonas Kulla
958af38442
Optimize archive reading
...
This should be almost as fast as reading unencrypted
files from disk now. I also don't see any possible further
optimizations, so this is probably as fast as it gets.
2013-10-04 07:52:40 +02:00
Jonas Kulla
a9fc44f79d
Fix filesystem init for relative 'gamePath's
2013-10-03 22:11:25 +02:00
Jonas Kulla
4ddc487f17
Fix a critical bug with seeking in archives
...
Also, other small cleanups on the way.
2013-10-03 22:09:35 +02:00
Jonas Kulla
d20b652155
No point in drawing spaces
2013-10-03 00:48:12 +02:00
Jonas Kulla
d8dab9c429
Start ifdef'ing out RGSS2 functionality
2013-10-02 22:40:09 +02:00
Jonas Kulla
751b9c3ae5
Clip text surface to texture bounds on fast upload
2013-10-02 21:39:44 +02:00
Jonas Kulla
bb70c39811
Ensure SDL_image and SDL_ttf initialize correctly
2013-10-02 13:50:58 +02:00
Jonas Kulla
0f58852e2b
Remove GL_ARB_imaging requirement
...
Mesa doesn't have it, and I'm not sure it really
serves any purpose at all.
2013-10-02 13:35:14 +02:00
Jonas Kulla
7b97075282
Remove unnecessary allocations
2013-10-01 18:27:22 +02:00
Jonas Kulla
a54acce6b7
Implement Bitmap 'blur'
...
I was a bit confused at first because I thought Enterbrain
had actually implemented a full Gaussian blur, but nope,
just dumb averaging.
2013-10-01 18:12:52 +02:00
Jonas Kulla
20ec560145
Wrap color clear in 'FBO::clear()' convenience function
2013-10-01 13:10:14 +02:00
Jonas Kulla
ceb7821362
Minor code style fix
2013-10-01 12:15:28 +02:00
Jonas Kulla
8baa76541c
Merge branch 'bitmap_blur'
2013-10-01 12:06:40 +02:00
Jonas Kulla
baff4e362e
Fix minor GPU timer query issue
2013-10-01 12:05:58 +02:00
Jonas Kulla
9f26ff9fb0
Port over Bitmap 'radial_blur' from old SFML codebase
...
This implementation is also heaps better than the old
one as it doesn't use a (differently sized) aux texture,
meaning the Bitmap discards its old texture and aquires
one of same size, making reuse through the TexPool a
lot more likely. It also saves on the aux texture blits
and binding switches.
As the setup / resource acquisition far outweighs the
actual rendering cost, operation time is relatively
constant no matter how many divisions are used.
2013-10-01 12:03:20 +02:00
Jonas Kulla
b5afeadb5b
Fix null deref
2013-10-01 02:29:02 +02:00
Jonas Kulla
73d5cb5bad
Comment out unsupported audio formats
2013-10-01 02:28:46 +02:00
Jonas Kulla
408864339f
Implement case insensitive path resolution
2013-09-30 21:20:29 +02:00
Jonas Kulla
f49b03ba23
Window: Always rebuild cursor_rect tex coords
...
If the same Window updated its control verts without a visble
cursor_rect, these tex coords will get randomly overwritten by
further control parts.
2013-09-30 19:32:45 +02:00
Jonas Kulla
05f73f0b98
Ensure Elements don't unlink from an already dead Scene
2013-09-30 19:30:27 +02:00
Jonas Kulla
9d34fc966b
Tilemap: Clamp sampled tileset height to multiple of 32
2013-09-30 01:38:46 +02:00
Jonas Kulla
2226927b08
Null deref fixes / cleanups
2013-09-28 21:48:02 +02:00
Jonas Kulla
1737ec9af4
Fix 'Rect::isEmpty()' and small performance fixes
...
Specifically, don't emit the 'valueChanged' signal
if nothing actually changed.
2013-09-28 21:45:33 +02:00
Jonas Kulla
4c06b676ad
Spacing and minor fixes
2013-09-28 21:30:51 +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
12c92d6dd0
Fix Tilemap's scanrow z sorting for good
...
Also make it a tad faster.
2013-09-27 04:42:22 +02:00
Jonas Kulla
97d0794c7c
Remove Serializable's virtual destructor. It didn't do anything anyway.
...
To still make the compiler happy, add virtual destructors
to all descendants of Serializable.
2013-09-27 04:39:35 +02:00
Jonas Kulla
92ab65ba52
Fix window opacity not being applied on vert (re)construction
2013-09-27 04:37:56 +02:00
Jonas Kulla
43aacc13d9
Add equality op that compares against a clamped integer
2013-09-27 00:55:48 +02:00
Jonas Kulla
35521c25c0
Don't hide cursor when window isn't focused
2013-09-25 20:35:00 +02:00
Jonas Kulla
dff2d79a70
Implement blits from mega surfaces to regular Bitmaps
...
This is used in events that take their sprite from a tile
out of the tileset.
2013-09-25 17:07:43 +02:00
Jonas Kulla
0fc6022dd0
Use BlitSurface instead of UpperBlit (for forward-compat)
2013-09-25 17:07:26 +02:00
Jonas Kulla
cfcfc2fd5e
Fix wrong pixel format specified for upload
2013-09-25 15:13:45 +02:00
Jonas Kulla
0a17f9ccad
Return advance as width for italic characters
2013-09-25 13:49:54 +02:00
Jonas Kulla
32361e513a
Track 'tainted' area of Bitmaps to optimize blit operations
...
The 'tainted' area of a Bitmap describes what parts are no
longer in a 'cleared' state. When we blit to a fully cleared
are of a Bitmap at full opacity, we can completely disregard
the existing pixels in the operation, meaning we can skip any
blending calculations and just blit / upload straight to the
texture. This greatly speeds up text message rendering.
In the process, pixman has become a new dependency for mkxp,
but the results of this optimization are well worth it!
2013-09-25 13:49:24 +02:00
Jonas Kulla
e903d8cb0f
One last null pointer deref slipped through ;)
2013-09-24 23:00:16 +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
a9454fdf9c
Fix nullpointer deref
2013-09-24 22:42:10 +02:00