Export DLL symbols
This commit is contained in:
@@ -28,6 +28,13 @@
|
|||||||
#define RUBBERBAND_API_MAJOR_VERSION 2
|
#define RUBBERBAND_API_MAJOR_VERSION 2
|
||||||
#define RUBBERBAND_API_MINOR_VERSION 6
|
#define RUBBERBAND_API_MINOR_VERSION 6
|
||||||
|
|
||||||
|
#undef RUBBERBAND_DLLEXPORT
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
#define RUBBERBAND_DLLEXPORT __declspec(dllexport)
|
||||||
|
#else
|
||||||
|
#define RUBBERBAND_DLLEXPORT
|
||||||
|
#endif
|
||||||
|
|
||||||
#include <vector>
|
#include <vector>
|
||||||
#include <map>
|
#include <map>
|
||||||
#include <cstddef>
|
#include <cstddef>
|
||||||
@@ -60,7 +67,8 @@
|
|||||||
namespace RubberBand
|
namespace RubberBand
|
||||||
{
|
{
|
||||||
|
|
||||||
class RubberBandStretcher
|
class RUBBERBAND_DLLEXPORT
|
||||||
|
RubberBandStretcher
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -32,6 +32,13 @@ extern "C" {
|
|||||||
#define RUBBERBAND_API_MAJOR_VERSION 2
|
#define RUBBERBAND_API_MAJOR_VERSION 2
|
||||||
#define RUBBERBAND_API_MINOR_VERSION 6
|
#define RUBBERBAND_API_MINOR_VERSION 6
|
||||||
|
|
||||||
|
#undef RB_EXTERN
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
#define RB_EXTERN extern __declspec(dllexport)
|
||||||
|
#else
|
||||||
|
#define RB_EXTERN extern
|
||||||
|
#endif
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This is a C-linkage interface to the Rubber Band time stretcher.
|
* This is a C-linkage interface to the Rubber Band time stretcher.
|
||||||
*
|
*
|
||||||
@@ -91,52 +98,54 @@ typedef int RubberBandOptions;
|
|||||||
struct RubberBandState_;
|
struct RubberBandState_;
|
||||||
typedef struct RubberBandState_ *RubberBandState;
|
typedef struct RubberBandState_ *RubberBandState;
|
||||||
|
|
||||||
extern RubberBandState rubberband_new(unsigned int sampleRate,
|
RB_EXTERN RubberBandState rubberband_new(unsigned int sampleRate,
|
||||||
unsigned int channels,
|
unsigned int channels,
|
||||||
RubberBandOptions options,
|
RubberBandOptions options,
|
||||||
double initialTimeRatio,
|
double initialTimeRatio,
|
||||||
double initialPitchScale);
|
double initialPitchScale);
|
||||||
|
|
||||||
extern void rubberband_delete(RubberBandState);
|
RB_EXTERN void rubberband_delete(RubberBandState);
|
||||||
|
|
||||||
extern void rubberband_reset(RubberBandState);
|
RB_EXTERN void rubberband_reset(RubberBandState);
|
||||||
|
|
||||||
extern void rubberband_set_time_ratio(RubberBandState, double ratio);
|
RB_EXTERN void rubberband_set_time_ratio(RubberBandState, double ratio);
|
||||||
extern void rubberband_set_pitch_scale(RubberBandState, double scale);
|
RB_EXTERN void rubberband_set_pitch_scale(RubberBandState, double scale);
|
||||||
|
|
||||||
extern double rubberband_get_time_ratio(const RubberBandState);
|
RB_EXTERN double rubberband_get_time_ratio(const RubberBandState);
|
||||||
extern double rubberband_get_pitch_scale(const RubberBandState);
|
RB_EXTERN double rubberband_get_pitch_scale(const RubberBandState);
|
||||||
|
|
||||||
extern unsigned int rubberband_get_latency(const RubberBandState);
|
RB_EXTERN unsigned int rubberband_get_latency(const RubberBandState);
|
||||||
|
|
||||||
extern void rubberband_set_transients_option(RubberBandState, RubberBandOptions options);
|
RB_EXTERN void rubberband_set_transients_option(RubberBandState, RubberBandOptions options);
|
||||||
extern void rubberband_set_detector_option(RubberBandState, RubberBandOptions options);
|
RB_EXTERN void rubberband_set_detector_option(RubberBandState, RubberBandOptions options);
|
||||||
extern void rubberband_set_phase_option(RubberBandState, RubberBandOptions options);
|
RB_EXTERN void rubberband_set_phase_option(RubberBandState, RubberBandOptions options);
|
||||||
extern void rubberband_set_formant_option(RubberBandState, RubberBandOptions options);
|
RB_EXTERN void rubberband_set_formant_option(RubberBandState, RubberBandOptions options);
|
||||||
extern void rubberband_set_pitch_option(RubberBandState, RubberBandOptions options);
|
RB_EXTERN void rubberband_set_pitch_option(RubberBandState, RubberBandOptions options);
|
||||||
|
|
||||||
extern void rubberband_set_expected_input_duration(RubberBandState, unsigned int samples);
|
RB_EXTERN void rubberband_set_expected_input_duration(RubberBandState, unsigned int samples);
|
||||||
|
|
||||||
extern unsigned int rubberband_get_samples_required(const RubberBandState);
|
RB_EXTERN unsigned int rubberband_get_samples_required(const RubberBandState);
|
||||||
|
|
||||||
extern void rubberband_set_max_process_size(RubberBandState, unsigned int samples);
|
RB_EXTERN void rubberband_set_max_process_size(RubberBandState, unsigned int samples);
|
||||||
extern void rubberband_set_key_frame_map(RubberBandState, unsigned int keyframecount, unsigned int *from, unsigned int *to);
|
RB_EXTERN void rubberband_set_key_frame_map(RubberBandState, unsigned int keyframecount, unsigned int *from, unsigned int *to);
|
||||||
|
|
||||||
extern void rubberband_study(RubberBandState, const float *const *input, unsigned int samples, int final);
|
RB_EXTERN void rubberband_study(RubberBandState, const float *const *input, unsigned int samples, int final);
|
||||||
extern void rubberband_process(RubberBandState, const float *const *input, unsigned int samples, int final);
|
RB_EXTERN void rubberband_process(RubberBandState, const float *const *input, unsigned int samples, int final);
|
||||||
|
|
||||||
extern int rubberband_available(const RubberBandState);
|
RB_EXTERN int rubberband_available(const RubberBandState);
|
||||||
extern unsigned int rubberband_retrieve(const RubberBandState, float *const *output, unsigned int samples);
|
RB_EXTERN unsigned int rubberband_retrieve(const RubberBandState, float *const *output, unsigned int samples);
|
||||||
|
|
||||||
extern unsigned int rubberband_get_channel_count(const RubberBandState);
|
RB_EXTERN unsigned int rubberband_get_channel_count(const RubberBandState);
|
||||||
|
|
||||||
extern void rubberband_calculate_stretch(RubberBandState);
|
RB_EXTERN void rubberband_calculate_stretch(RubberBandState);
|
||||||
|
|
||||||
extern void rubberband_set_debug_level(RubberBandState, int level);
|
RB_EXTERN void rubberband_set_debug_level(RubberBandState, int level);
|
||||||
extern void rubberband_set_default_debug_level(int level);
|
RB_EXTERN void rubberband_set_default_debug_level(int level);
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#undef RB_EXTERN
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
Reference in New Issue
Block a user