05-07-2018, 10:50 PM
(05-06-2018, 03:33 AM)PerspexSphinx Wrote: I was just wondering though, why for MIX, there is just set values... MIX, MIX25, MIX50 & MIX75, why can’t one just enter any amount of MIX like MIX15 or MIX45? And why couldn’t one do that for the amount of ADD, SUB or MOD or is this done with the CUSTOM mode?The MIXxx, ADD, SUB (etc) identifiers map to a set of precalculated look-up tables (LUTs) that encode the required math and clamping in just one memory access to speed-up rendering. Very few 2D classic systems had transparency (the SNES) and they were predefined modes. Tilengine uses this concept with some extra modes, and the CUSTOM mode where you can provide your own blending function with Engine :: set_custom_blend_function()
(05-06-2018, 03:33 AM)PerspexSphinx Wrote: Also started playing with sound... got a “wave” sound effect to work but can one use other formats? And can one add a sound track? If so how and in what format?Tilengine itself doesn't provide any sound capability, this is left to external libraries. If you want an open source, cross-platform and cross-language, then check out SDL and its companion SDL_Mixer that supports many formats for sound and music. This is the library I use in the python platformer example, with a python binding called PySDL2