0227b7a61d
Issue #872 : Fix float overflow in plasma transition shader
2025-02-28 11:37:39 +01:00
fa67d837a5
Add user sprite functions to C API.
2025-02-27 16:57:03 +01:00
631573a4f0
Add user sprite proxy functions to ProjectM class.
2025-02-27 15:55:14 +01:00
9266716ef6
Implement user sprite manager and factory
2025-02-27 15:55:14 +01:00
760a4c9c95
Add Milkdrop user sprites
2025-02-27 15:55:14 +01:00
f0bad56ca1
Treat keys in FileParser case-insensitively
...
Presets and user sprites could use any casing for the keys, so we should also behave properly.
2025-02-27 15:55:14 +01:00
86164bece1
Remove misleading ToDo comments for title and sprite drawing.
2025-02-27 15:55:14 +01:00
5eb037efc1
Make shader resource file generation reusable
2025-02-27 15:55:14 +01:00
fbdb18b355
Move FileParser to main directory.
...
Makes it easier to reuse for loading sprites.
2025-02-27 15:55:13 +01:00
1ed2967e35
Add transition/blending progress to render context
2025-02-27 15:55:13 +01:00
458a63d8a5
Cache compiled static preset shaders
2025-02-27 15:55:13 +01:00
a2e9a91651
Add a global shader cache
2025-02-27 15:55:07 +01:00
9f47262a18
Add both long and short sampler names for random textures.
...
If a preset uses different long-form samplers for a single random slot, this will result in a failure, e.g. using both "sampler_rand00_something" and "sampler_rand00_else". As this also isn't supported by Milkdrop and would create a conflict situation, we don't care.
2024-12-16 17:49:16 +01:00
f2a0277ddd
Fix texture loading if casing mismatches filename
...
Always use lower-case unqualified names to find and cache the actual textures.
2024-10-07 12:08:44 +02:00
1711511f36
Fixed variable using reserved word in vertex shader
...
OpenGL ES has a distance() function, and thus, the shader may fail to compile in some drivers, e.g. some Android releases.
2024-08-04 17:04:45 +02:00
4e9040f338
Properly check for uninitialized texture in CopyTexture class.
...
Before rendering the first frame, there is no output texture present in a preset, so we can't copy anything and should just skip that step.
2024-07-12 14:25:28 +02:00
f94f99d888
Make preset transitions use TimeKeeper instead of the system clock
2024-06-09 13:04:01 +02:00
2914d85ec3
Add API functions to set and retrieve frame times
...
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.
2024-06-09 12:51:35 +02:00
bd2b1ba9f4
Add API function to enable rendering to custom FBO IDs
2024-06-08 17:22:23 +02:00
b0cdf4de7b
Add optional FBO ID parameter to render function.
...
This will allow external apps to pass in any custom FBO to render to. Defaults to 0, keeping previous behavior if not given.
2024-06-08 17:22:23 +02:00
91f329111f
Hard-code internal noise texture format for GL Core profiles
...
glGetInternalformativ() also is an addition in OpenGL Core 4.2, which we don't officially support.
2024-05-13 17:55:26 +02:00
e538ccc615
Fix bug that prevents composite shader from being loaded
...
Happens in the rare cases if a preset has no warp shader
2024-03-19 23:14:10 +01:00
861c36e41b
Scale and smooth samples for non-custom waveforms
2024-02-21 16:12:31 +01:00
3aa48a3f99
Modify NaN propagation for multiplication
2024-02-21 14:36:35 +01:00
0c27e8164a
Mimic Milkdrop code when handling RGBA values outside [0.0, 1.0]
2024-02-21 14:12:33 +01:00
d6b6446ac9
Make sure easter egg value is >0.
...
Gaussian distribution requires the sigma value to be >0. If the value is too small, we just use the default 1.0 value.
2024-02-15 18:11:46 +01:00
1477664182
Move noise texture creation into MilkdropNoise class.
...
No need to create an instance of the class as all generators are static. Use std::vector instead of C-style pointers as pixel buffer.
2024-02-15 18:11:39 +01:00
2eb1e41f5f
Pre-allocate vertex buffers for warp/comp meshes and borders
2024-02-12 16:39:18 +01:00
fcafa568cd
Improve performance with vertex buffer updates
...
In wave/shape drawing code, we now preallocate the vertex buffer once for the maximum number of sides and only update the existing buffer instead of reallocating it over and over again. Trades a few KB of additional RAM for a good amount of drawing performance.
In the motion vector grid code, we only reallocate the buffer if we draw more vertices than in the previous draw call.
Also changed the drawing hint to GL_STREAM_DRAW, which is slightly better suited for this kind of usage (update once, draw once, repeat).
These changes should hopefully improve performance, especially when large numbers of custom shapes are drawn.
2024-02-12 15:14:16 +01:00
f22cc42a61
Added requested revision
2024-02-11 22:40:11 +01:00
0067e82f7e
Fix various typos
...
Found via `codespell -q 3 -S "./vendor" -L ist`
2024-02-11 22:40:11 +01:00
d82c031671
Use PRJM_EVAL_F in ShapePerFrameContext
2024-02-09 20:30:42 -06:00
12db8d9b94
Fix buffer overrun in WaveformMath
...
32 excess samples were read from the preset state in waveform modes. Didn't have any noticeable impact, but we should clearly not read over the end of an array.
2024-02-09 21:37:58 +01:00
5c0d61cff7
Use renderContext for preset state time, frame, fps, progress
2024-02-06 16:41:31 -06:00
bd7d5574a2
Keep active preset running if loading fails.
...
Also don't cancel any transition in progress etc., so if the app retries with a different preset, we only smoothly transition to the new, working one.
2024-02-06 15:11:52 +01:00
c5ecad05db
Format cleanup
2024-02-06 07:58:32 -06:00
0ea5bba3d7
WaveformAligner test fixes
2024-02-06 07:58:32 -06:00
305f78f177
Split WaveformAligner up into multiple testable methods
2024-02-06 07:58:32 -06:00
bd592bdb2e
Rename WaveformAligner variables to be clearer, add comments
2024-02-06 07:58:32 -06:00
7c425f7469
WaveformAligner type refactor
2024-02-06 07:58:32 -06:00
0beb7a2d09
Relocated dll's to PROJECTM_BIN_DIR on Windows
2024-02-02 10:21:25 -06:00
60e5607877
Fixed a bug in TextureManager, failed to load textures if prefixes (fw_...) were used.
2024-02-02 15:08:05 +01:00
a1d300f48c
Include cleanup, plus a few small code improvements.
...
Also removed empty FrameAudioData implementation file.
2024-02-02 15:08:05 +01:00
27f3308ac3
Remove utterly useless multithreading switch
...
Since we're using OpenGL, everything has to be done in the same thread anyways. Besides that, the actual "multithreading" implementation was basically starting an empty thread that did absolutely nothing, then wait synchronously for it to complete and join it on the next frame.
2024-02-02 15:08:04 +01:00
184766b2c8
pkgconfig fixes
2024-02-02 15:08:04 +01:00
df48f1bb07
Remove RandomNumberGenerators.hpp and replace the only invocation with std::normal_distribution
2024-02-02 15:08:04 +01:00
0789c54404
Remove unnecessary feature detections, move filesystem defines to config.h.
2024-02-02 15:08:04 +01:00
170f054860
Remove no longer used LLVM support code.
2024-02-02 15:08:04 +01:00
1513675c31
Remove no longer used omptl and OpenMP support.
...
Fixup: remove omtpl
2024-02-02 15:08:04 +01:00
7e45cbe1f9
Clean up minor warnings and code style
...
* Remove warnings for code in vendor folders
* Add pedantic and extra warnings in GCC only to projectM sources
* Rename ResetOpenGL to SetWindowSize
2024-02-01 11:27:10 -06:00