Commit Graph

36 Commits

Author SHA1 Message Date
mara ac8f4b1594 build: Support SDL_sound in different prefix as SDL2
As the required SDL_sound is a custom fork which is not packaged as
system package, it could plausibly be installed in a different path.
2021-09-03 07:43:11 +02:00
Luis Caceres 43cb318862 Config: Add case-insensitive ini file parser 2019-03-19 19:26:50 +01:00
Carsten Teibes b1bdf1e445 Fix CMake build, only use `resource.h` on Windows
This was broken in commit 01e17ed5c6 (move windows specific files).
2017-08-18 22:42:27 +02:00
Marty Plummer 01e17ed5c6 windows: move windows specific files
Moved the windows-specific files into their own subdir for
cleanliness's sake and mesonbuild organization.

Signed-off-by: Marty Plummer <ntzrmtthihu777@gmail.com>
2017-08-10 21:58:31 +02:00
Marty Plummer f5c30affaa mingw-w64: allow cmake cross-compile
Tested on gentoo with x86_64-w64-mingw32 toolchain and libraries.

Signed-off-by: Marty Plummer <ntzrmtthihu777@gmail.com>
2017-05-25 13:01:11 +02:00
Jonas Kulla 373b90af00 Graphics: Optimize Viewport effect rendering
Using the kitchen sink plane shader for viewport effects, even
if only a small part of them are active, incurs great performance
loss on mobile, so split the rendering into multiple optional
passes which additionally use the blending hardware for faster
mixing (lerping).
Also, don't mirror the PingPong textures if the viewport effect
covers the entire screen area anyway.
2014-12-31 18:52:19 +01:00
Jonas Kulla 3c0a530eba Sprite: Add special case shader for translucent effect
Translucent sprites (opacity < 255) are very common,
so using a custom shader instead of the full blown effect one
helps a lot, especially on mobile.
2014-12-31 18:52:19 +01:00
Jonas Kulla a53163660f Shader: Refine preprocessing on GLES platform
Don't globally set float precision to mediump, only fragment
shaders need that and defining it for vertex shaders causes
tilemap cracks.

Also manually define low precision for variables that hold
color / alpha values.
2014-12-31 18:52:19 +01:00
Jonas Kulla 60f101f2e6 Tilemap(VX): Factor out common code into tilemap-common.h
Renamed flashmap.h to tilemap-common.h as it already contained
shared functions.
2014-11-30 17:46:28 +01:00
Jonas Kulla c1aab96454 Rename src/debuglogger -> src/gl-debug 2014-11-29 17:51:37 +01:00
Jonas Kulla 5979c5f778 Add placeholder application icon 2014-11-29 17:30:53 +01:00
Jonas Kulla 577f606dac Tilemap: Factor out flash tile code
This will be reused later in TilemapVX.
2014-10-26 20:00:56 +01:00
Jonas Kulla dd73db2e9d Introduce F1 menu to reconfigure key bindings at runtime 2014-10-11 20:48:44 +02:00
Jonas Kulla c1d89e4f8d CMakeLists.txt: Bump default MRI version to 2.1 2014-10-03 20:15:52 +02:00
Jonas Kulla 5ea964eee8 CMakeLists.txt: Link against libiconv on OSX 2014-09-30 14:17:33 +02:00
Jonas Kulla 51a0f3903c Audio: Clean up threading and add AudioStream fadein (RGSS3) 2014-09-30 09:13:12 +02:00
Jonas Kulla 46497eae01 CMakeLists.txt: Add missing shader source 2014-09-30 01:34:10 +02:00
Jonas Kulla 757a1d5e39 Load fluidsynth entrypoints dynamically (and make them optional)
This removes the static dependency on fluidsynth being present
at buildtime (even headers aren't needed anymore).

Even though midi is a default format for the RPG XP/VX series,
it has fallen more and more out of use, with VX Ace completely
abandoning it from the RTP and making ogg vorbis the de facto
standard. Midi support is kept for legacy reasons, but isn't
encouraged. On top of all this, fluidsynth together with glib
is a heavy dependency that often times won't even be used.
Making it optional at build time is an attempt to unify and
keep build config fragmentation low.

In RGSS3, fluidsynth / midi is not initialized at all by
default, but rather on demand when either a midi track is
played back or Audio.setup_midi is called.
2014-09-09 00:08:32 +02:00
Jonas Kulla 55f1542c76 Merge separate RGSS version build configs into one
Setup active RGSS version at runtime. Desired version can be
specified via config, or as default, auto detected from the game
files. This removes the need to build specifically for each
version, which should help packaging a lot.

This also greatly reduces the danger of introducing code that
wouldn't compile on all RGSS version paths (as certain code paths
were completely ifdef'd out).

This can be optimized more, eg. not compiling shaders that aren't
needed in the active version.
2014-08-28 23:22:05 +02:00
Jonas Kulla 4daff93e29 Put bundled font into its own translation unit 2014-08-17 00:26:35 +02:00
Jonas Kulla 3bcf995832 Add option to turn off switching into executable dir on startup 2014-08-02 09:30:17 +02:00
Jonas Kulla 751fdc599e Audio: Add MIDI format playback support
This adds a new dependency with libfuildsynth. MIDI support
is built by default, but can be disabled if not desired.

All RTP songs should work well, but there are known problems
with other files (see README). Also, the pitch shift implementation
is somewhat poor and doesn't match RMXP (at least subjectively).

A soundfont is not included and must be provided by
the user themself.
2014-08-02 06:42:55 +02:00
Jonas Kulla d7e0429ea6 CMakeLists.txt: Add 'vorbisfile' to dependencies if RGSS2=ON
Also add missing define.
2014-07-25 15:19:10 +02:00
Jonas Kulla 0d96207b39 CMakeLists.txt: Don't turn on "RGSS2" by default 2014-07-25 14:47:08 +02:00
Jonas Kulla 1ecdd9f980 filesystem.cpp: Split out RGSSAD parts 2014-07-23 22:57:39 +02:00
Jonas Kulla f73b0ba4b5 audio.cpp: Split up into smaller parts 2014-07-23 17:28:20 +02:00
Thomas Schneider 20db1a7b39 Added some cmake deps 2014-07-13 22:18:27 +02:00
Jonas Kulla c0f25548bd CMakeLists.txt: Add new file "tilemap.vert" 2014-07-09 17:11:05 +02:00
Jonas Kulla 282d547ad4 Remove Perftimer classes
Performance can still be crudely measured by turning off
the framelimit and observing the FPS count. For everything
else, there's always callgrind / apitrace.
2014-06-13 19:01:15 +02:00
Jonas Kulla 6c481e5eb8 Eliminate GLEW dependency
GL entrypoint resolution is now done manually. This has a couple
immediate benefits, such as not having to retrieve hundreds of
functions pointers that we'll never use. It's also nice to have
an exact overview of all the entrypoints used by mkxp.

This change allows mkxp to run fine with core contexts, not sure
how relevant that is going to be in the future.

What's noteworthy is that  _all_ entrypoints, even the ones core
in 1.1 and guaranteed to be in every libGL, are resolved
dynamically.
This has the added benefit of not having to link directly against
libGL anymore, which also cleans up the output of `ldd` quite
a bit (SDL2 loads most system deps dynamically at runtime).

GL headers are still required at build time.
2014-06-13 18:46:45 +02:00
Edward Rudd 05668f792a small tweaks to cmake for linux 2014-01-01 14:54:19 -05:00
Edward Rudd 1ce4970d62 setup source groups in the cmake to make IDEs more organized 2014-01-01 11:19:31 -05:00
Edward Rudd 835ea686c8 make indents consistent in cake.. also put a glaring note that the MRUBY support needs to be finished. 2014-01-01 10:46:33 -05:00
Edward Rudd f106e31c6f add missed force32 option 2013-12-31 16:36:00 -05:00
Edward Rudd 02738be4c5 CMake's GLEW finds parent dir.. not GL subdir. 2013-12-31 16:31:58 -05:00
Edward Rudd b1a2569dff add CMake project for easier building 2013-12-31 16:24:14 -05:00