Commit Graph

2487 Commits

Author SHA1 Message Date
a88f62360a Add version header and API methods to get build/run time versions of libprojectM. 2023-01-24 20:03:44 +01:00
a85f9c61ef Add OpenMP libraries and flags to libprojectM pkg-config file. 2023-01-24 19:19:53 +01:00
ebafd69dfb Create proper pkg-config file for libprojectM_playlist.
Generalized the generator code as a macro. Still a huge mess.
2023-01-24 19:13:07 +01:00
2287172cbb Create proper pkg-config file for libprojectM.
Should now support both static and shared libs, plus adding any other required flags.
2023-01-24 18:49:37 +01:00
bcaf98f2f1 Rename USE_THREADS to PROJECTM_USE_THREADS and export it in the package config file.
PROJECTM_USE_THREADS is only exported if ENABLE_CXX_INTERFACE is ON.
2023-01-24 17:56:12 +01:00
97519a81e6 Set default symbol visibility to hidden.
Only export API symbols, keep everything else hidden. C++ API will only expose the ProjectM and PCM classes, but no internals.

If devs want to have full access to projectM's internals, they need to adapt the build process to their own needs.
2023-01-24 17:49:55 +01:00
bff9e52c69 Reduce header footprint of optional C++ API files and export C++ symbols properly. 2023-01-24 17:47:39 +01:00
1f33c810b3 Split up API headers into smaller, categorized files.
Also updated copyright and prefixed the render-related function with "opengl".
2023-01-18 12:57:57 +01:00
05a2f2a41a GitHub Actions: Add static library build jobs for desktop platforms. 2023-01-17 20:00:44 +01:00
c6be80a491 GitHub Actions: Update local package lists before installing dependencies. 2023-01-17 18:58:03 +01:00
bac2a7ae12 Fix playlist tests on Windows.
Removed dependency on projectMtarget alltogether, as the playlist tests don't need the core library at all, only a few API functions which are mocked. Also made sure the mocked functions are declared as dllexport on Windows to match the dllimport declspec in the playlist library.
2023-01-17 18:55:29 +01:00
edbe7455da macOS: Link CoreFoundation framework to the projectM library. 2023-01-17 18:55:23 +01:00
6e795ec632 Only build either shared or static projectM and playlist libraries.
Target name is now just libprojectM::projectM for the main library instead of libprojectM::static or libprojectM::shared.

Now using CMake's default mechanism to select the resulting library type via the BUILD_SHARED_LIBS variable. Main use case will be working with the shared library, which is the default.

Playlist library now also builds as a shared library, including proper symbol exports.

Additionally, deleted the leftover TestRunner class and a few old and rather useless test cases.

Also added LLVM find_package call and as a link dependency if the build is configured for using (experimental) LLVM code.

Reorganized tests to link either one of the object libraries for unit testing.
2023-01-13 11:16:27 +01:00
f2615a1745 Change projectm_playlist_items() method to return a given range of items. 2023-01-07 18:37:23 +01:00
4d54a511d1 Add projectm_playlist_get_shuffle() method to playlist API 2023-01-07 18:37:22 +01:00
c8077a2145 Partially fix smooth blending.
There's still a sudden change between presets halfway through the transitions as the shaders are swapped, but fixing this would require a larger rewrite of how presets are rendered in the pipeline. Will do this later.
2023-01-07 15:52:51 +01:00
eb95939419 Clamp preset progress between 0.0 and 1.0 2023-01-07 15:52:51 +01:00
3dcb1f7a56 Fix preset change notification. 2023-01-07 15:52:51 +01:00
d7528f7e2e Pass new TextureManager pointer to ShaderEngine after resetting it. 2023-01-07 15:52:50 +01:00
48f291b51c Removed config file support and added temp fix for mesh size change.
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.
2023-01-07 15:52:50 +01:00
bbfc4f7170 Added API method for (re)setting texture search paths.
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.
2023-01-07 15:52:50 +01:00
22b0ccc423 Removed some unused offset parameters in Renderer methods. 2023-01-07 15:52:46 +01:00
2410adc92e Fix file type string 2023-01-05 07:24:26 -06:00
84af431219 Removed key handler from SDL test UI.
Also renamed a few members and add "[locked]" to window title when toggling the preset lock.
2022-12-30 15:15:10 +01:00
e659d862b5 Remove built-in key handler and rename two API functions.
Renamed preset lock functions to be in line with all other getter/setter functions regarding their naming scheme.
2022-12-30 15:14:25 +01:00
62c4585cd7 Temporarily disable FFT low-frequency test.
Values don't match for some reason, need to investigate this later. Spectrum looks good, so it's probably the test implementation that's wrong here.
2022-12-30 14:44:06 +01:00
a3275de8a1 cosmetic changes 2022-12-13 20:21:29 -06:00
c04e9b7eaf add push_release to workflow 2022-12-13 20:21:29 -06:00
55001567b0 Updated workflow name for emscripten.yml 2022-12-13 20:21:29 -06:00
fd1146c6a1 Temporarily disable emscripten unittest 2022-12-13 20:21:29 -06:00
dd021f450f Enable exception catching for emscripten 2022-12-13 20:21:29 -06:00
cddf1ec392 Temporarily disable FFT low-frequency test 2022-12-13 20:21:29 -06:00
a47c85fe64 Added windows build to workflow 2022-12-13 20:21:29 -06:00
2fbf44d8a8 Added macOs build to workflow 2022-12-13 20:21:29 -06:00
62bf7e7387 Added emscripten build to workflow 2022-12-13 20:21:29 -06:00
164e71ac31 Added linux build to workflow 2022-12-13 20:21:29 -06:00
e3bf3d801f Removed old workflow 2022-12-13 20:21:29 -06:00
28340ce32f Revert reordering of shader preprocessing statements.
Position of "shader_body" is reused in the next find call, which was broken because of the changed order.
2022-12-07 23:06:02 +01:00
b585017ba3 Fix a compile issue in emscripten by forward-declaring PipelineContext. 2022-12-06 15:03:10 +01:00
710d228fcf Add libprojectM include path for tests, as it was removed in the library definition. 2022-12-06 15:02:40 +01:00
c4f24ba5e7 Fix tests on Windows, use correct filter syntax in projectMPlaylistPlaylist_ApplyFilter test. 2022-12-05 12:04:16 +01:00
1429b57f87 Build fixes, expose fewer internals in headers by forward-declaring more types. 2022-12-05 11:46:43 +01:00
6485ec40fb Removed unused include in Renderer.cpp that made the build fail. 2022-12-04 22:26:42 +01:00
5189f249e3 Make SDL test UI compile & work again.
Still much to do here, especially in regards to key handling and config file parsing. For now, the app only load presets from the "presets" subdir of the current working directory.
2022-12-04 22:13:48 +01:00
42387a671b Add preset switched event formerly defined in projectM.h to playlist API 2022-12-04 21:54:29 +01:00
830dc74ff0 Catch directory access exceptions in Playlist class.
No error handling or feedback mechanism yet.
2022-12-04 21:53:36 +01:00
381fe4f51e Properly initialize idle preset and preset factory. 2022-12-04 21:51:36 +01:00
53ea059ec1 Fixed URL detection in PresetFactory 2022-12-04 21:51:03 +01:00
9ea98bf01e Add glob pattern filtering to playlist library.
Syntax is very similar to .gitignore glob syntax, with a few exceptions to simplify use.
2022-12-04 20:54:15 +01:00
a1ffd93e31 Add next/previous/last functions and playback history recording. 2022-11-26 23:47:04 +01:00