Remove PROJECTM_EXPORT from PCM class methods

PCM is an internal class with the C API (projectm_pcm_*) providing
the public interface. Exporting these methods caused symbols to leak
into the shared library even when ENABLE_CXX_INTERFACE was off.

Fixes #937
This commit is contained in:
Mischa
2026-01-10 11:58:40 -08:00
parent 014fb59dd5
commit c6a8823814

View File

@ -13,8 +13,6 @@
#include "Audio/MilkdropFFT.hpp"
#include "Audio/WaveformAligner.hpp"
#include <projectM-4/projectM_export.h>
#include <atomic>
#include <cstdint>
#include <cstdlib>
@ -33,7 +31,7 @@ public:
* @param channels The number of channels in the input data.
* @param count The amount of samples in the buffer
*/
PROJECTM_EXPORT void Add(const float* samples, uint32_t channels, size_t count);
void Add(const float* samples, uint32_t channels, size_t count);
/**
* @brief Adds new mono unsigned 8-bit PCM data to the storage
@ -42,7 +40,7 @@ public:
* @param channels The number of channels in the input data.
* @param count The amount of samples in the buffer
*/
PROJECTM_EXPORT void Add(const uint8_t* samples, uint32_t channels, size_t count);
void Add(const uint8_t* samples, uint32_t channels, size_t count);
/**
* @brief Adds new mono signed 16-bit PCM data to the storage
@ -51,7 +49,7 @@ public:
* @param channels The number of channels in the input data.
* @param count The amount of samples in the buffer
*/
PROJECTM_EXPORT void Add(const int16_t* samples, uint32_t channels, size_t count);
void Add(const int16_t* samples, uint32_t channels, size_t count);
/**
* @brief Updates the internal audio data values for rendering the next frame.
@ -64,13 +62,13 @@ public:
* @param secondsSinceLastFrame Time passed since rendering the last frame. Basically 1.0/FPS.
* @param frame Frames rendered since projectM was started.
*/
PROJECTM_EXPORT void UpdateFrameAudioData(double secondsSinceLastFrame, uint32_t frame);
void UpdateFrameAudioData(double secondsSinceLastFrame, uint32_t frame);
/**
* @brief Returns a class holding a copy of the current frame audio data.
* @return A FrameAudioData class with waveform, spectrum and other derived values.
*/
PROJECTM_EXPORT auto GetFrameAudioData() const -> FrameAudioData;
auto GetFrameAudioData() const -> FrameAudioData;
private:
template<