Since this might be vendor-specific behavior, a new API function to configure the X/Y texel offsets has been added.
Signed-off-by: Kai Blaschke <kai.blaschke@kb-dev.net>
Calling the function with the same size again and again does not do anything at all - especially not "reset the renderer" as it was previously stated.
Signed-off-by: Kai Blaschke <kai.blaschke@kb-dev.net>
Setting a custom frame time will result in stable animation speeds if projectM does not render at real-time speeds, e.g. while encoding a video from an audio file as fast as possible.
$ git grep -l 'include "libprojectM/' | xargs sed 's,include "libprojectM/,include "projectM-4.0/,' -i
And then revert for src/libprojectM/*.hpp includes:
$ for i in $( cd src/libprojectM && ls -1 *.hpp ) ; do grep -Rl "#include \"projectM-4.0/${i}\"" | xargs -r sed "s,\"projectM-4.0/${i},\"libprojectM/${i}," -i ; done
Now projectm_create() will just return a NULL pointer instead of having the runtime library call SIGABRT.
In a later iteration, we may allow creation of the instance and just keep the renderer uninitialized. Users should then call a to-be-introduced renderer reinitialization function.
Mesh size is currently so deeply burrowed in the whole preset structure that changing it on the fly is basically impossible. For now, we'll reload the idle preset and reset the whole preset factory class tree to make sure all classes are properly reinitialized. If apps want to change the mesh size after startup, they need to reload the last played preset after changing the mesh size. This will be fixed in the future after the parser/equation compiler rewrite.
Was only possible on startup before, changing the paths required recreating the whole projectM instance. Now, the method will only reset the texture manager, but not the shaders and presets.
Lots of interconnected changes in this commit:
- Removed unnecessary name/author/filename members all over the place.
- Started using exceptions to deliver preset loading and rendering errors to the topmost ProjectM class.
- Added stream loading methods to factories and the base Preset class.
- Added new events for requesting preset switch and telling the user about loading errors.
- Consolidated preset switching logic in ProjectM class a bit.