| @@ -620,6 +620,7 @@ | |||
| */ | |||
| #import <QTOLibrary.dll> | |||
| #import <QTOControl.dll> | |||
| #endif | |||
| #if JUCE_MSVC | |||
| @@ -117414,7 +117415,7 @@ FLAC_API FLAC__bool FLAC__format_seektable_is_legal(const FLAC__StreamMetadata_S | |||
| } | |||
| /* used as the sort predicate for qsort() */ | |||
| static int seekpoint_compare_(const FLAC__StreamMetadata_SeekPoint *l, const FLAC__StreamMetadata_SeekPoint *r) | |||
| static int JUCE_CDECL seekpoint_compare_(const FLAC__StreamMetadata_SeekPoint *l, const FLAC__StreamMetadata_SeekPoint *r) | |||
| { | |||
| /* we don't just 'return l->sample_number - r->sample_number' since the result (FLAC__int64) might overflow an 'int' */ | |||
| if(l->sample_number == r->sample_number) | |||
| @@ -117434,7 +117435,7 @@ FLAC_API unsigned FLAC__format_seektable_sort(FLAC__StreamMetadata_SeekTable *se | |||
| FLAC__ASSERT(0 != seek_table); | |||
| /* sort the seekpoints */ | |||
| qsort(seek_table->points, seek_table->num_points, sizeof(FLAC__StreamMetadata_SeekPoint), (int (*)(const void *, const void *))seekpoint_compare_); | |||
| qsort(seek_table->points, seek_table->num_points, sizeof(FLAC__StreamMetadata_SeekPoint), (int (JUCE_CDECL *)(const void *, const void *))seekpoint_compare_); | |||
| /* uniquify the seekpoints */ | |||
| first = true; | |||
| @@ -136207,7 +136208,7 @@ static vorbis_info_floor *floor1_unpack (vorbis_info *vi,oggpack_buffer *opb){ | |||
| return(NULL); | |||
| } | |||
| static int icomp(const void *a,const void *b){ | |||
| static int JUCE_CDECL icomp(const void *a,const void *b){ | |||
| return(**(int **)a-**(int **)b); | |||
| } | |||
| @@ -138703,7 +138704,7 @@ static void cheby(float *g, int ord) { | |||
| } | |||
| } | |||
| static int comp(const void *a,const void *b){ | |||
| static int JUCE_CDECL comp(const void *a,const void *b){ | |||
| return (*(float *)a<*(float *)b)-(*(float *)a>*(float *)b); | |||
| } | |||
| @@ -142004,7 +142005,7 @@ float **_vp_quantize_couple_memo(vorbis_block *vb, | |||
| } | |||
| /* this is for per-channel noise normalization */ | |||
| static int apsort(const void *a, const void *b){ | |||
| static int JUCE_CDECL apsort(const void *a, const void *b){ | |||
| float f1=fabs(**(float**)a); | |||
| float f2=fabs(**(float**)b); | |||
| return (f1<f2)-(f1>f2); | |||
| @@ -143433,7 +143434,7 @@ int vorbis_book_init_encode(codebook *c,const static_codebook *s){ | |||
| return(0); | |||
| } | |||
| static int sort32a(const void *a,const void *b){ | |||
| static int JUCE_CDECL sort32a(const void *a,const void *b){ | |||
| return ( **(ogg_uint32_t **)a>**(ogg_uint32_t **)b)- | |||
| ( **(ogg_uint32_t **)a<**(ogg_uint32_t **)b); | |||
| } | |||
| @@ -237313,19 +237314,19 @@ namespace PNGHelpers | |||
| { | |||
| using namespace pnglibNamespace; | |||
| static void readCallback (png_structp png, png_bytep data, png_size_t length) | |||
| static void JUCE_CDECL readCallback (png_structp png, png_bytep data, png_size_t length) | |||
| { | |||
| static_cast<InputStream*> (png_get_io_ptr (png))->read (data, (int) length); | |||
| } | |||
| static void writeDataCallback (png_structp png, png_bytep data, png_size_t length) | |||
| static void JUCE_CDECL writeDataCallback (png_structp png, png_bytep data, png_size_t length) | |||
| { | |||
| static_cast<OutputStream*> (png_get_io_ptr (png))->write (data, (int) length); | |||
| } | |||
| struct PNGErrorStruct {}; | |||
| static void errorCallback (png_structp, png_const_charp) | |||
| static void JUCE_CDECL errorCallback (png_structp, png_const_charp) | |||
| { | |||
| throw PNGErrorStruct(); | |||
| } | |||
| @@ -249218,6 +249219,9 @@ void MidiOutput::sendMessageNow (const MidiMessage& message) | |||
| #define log(a) {} | |||
| #endif | |||
| #define JUCE_ASIOCALLBACK // should probably use this to define the callback type, but | |||
| // the asio header doesn't actually specify a calling convention for the functions.. | |||
| #if ASIO_DEBUGGING | |||
| static void logError (const String& context, long error) | |||
| { | |||
| @@ -250362,7 +250366,7 @@ private: | |||
| return error; | |||
| } | |||
| void callback (const long index) | |||
| void JUCE_ASIOCALLBACK callback (const long index) | |||
| { | |||
| if (isStarted) | |||
| { | |||
| @@ -250507,7 +250511,7 @@ private: | |||
| asioObject->outputReady(); | |||
| } | |||
| static ASIOTime* bufferSwitchTimeInfoCallback0 (ASIOTime*, long index, long) | |||
| static ASIOTime* JUCE_ASIOCALLBACK bufferSwitchTimeInfoCallback0 (ASIOTime*, long index, long) | |||
| { | |||
| if (currentASIODev[0] != 0) | |||
| currentASIODev[0]->callback (index); | |||
| @@ -250515,7 +250519,7 @@ private: | |||
| return 0; | |||
| } | |||
| static ASIOTime* bufferSwitchTimeInfoCallback1 (ASIOTime*, long index, long) | |||
| static ASIOTime* JUCE_ASIOCALLBACK bufferSwitchTimeInfoCallback1 (ASIOTime*, long index, long) | |||
| { | |||
| if (currentASIODev[1] != 0) | |||
| currentASIODev[1]->callback (index); | |||
| @@ -250523,7 +250527,7 @@ private: | |||
| return 0; | |||
| } | |||
| static ASIOTime* bufferSwitchTimeInfoCallback2 (ASIOTime*, long index, long) | |||
| static ASIOTime* JUCE_ASIOCALLBACK bufferSwitchTimeInfoCallback2 (ASIOTime*, long index, long) | |||
| { | |||
| if (currentASIODev[2] != 0) | |||
| currentASIODev[2]->callback (index); | |||
| @@ -250531,40 +250535,40 @@ private: | |||
| return 0; | |||
| } | |||
| static void bufferSwitchCallback0 (long index, long) | |||
| static void JUCE_ASIOCALLBACK bufferSwitchCallback0 (long index, long) | |||
| { | |||
| if (currentASIODev[0] != 0) | |||
| currentASIODev[0]->callback (index); | |||
| } | |||
| static void bufferSwitchCallback1 (long index, long) | |||
| static void JUCE_ASIOCALLBACK bufferSwitchCallback1 (long index, long) | |||
| { | |||
| if (currentASIODev[1] != 0) | |||
| currentASIODev[1]->callback (index); | |||
| } | |||
| static void bufferSwitchCallback2 (long index, long) | |||
| static void JUCE_ASIOCALLBACK bufferSwitchCallback2 (long index, long) | |||
| { | |||
| if (currentASIODev[2] != 0) | |||
| currentASIODev[2]->callback (index); | |||
| } | |||
| static long asioMessagesCallback0 (long selector, long value, void*, double*) | |||
| static long JUCE_ASIOCALLBACK asioMessagesCallback0 (long selector, long value, void*, double*) | |||
| { | |||
| return asioMessagesCallback (selector, value, 0); | |||
| } | |||
| static long asioMessagesCallback1 (long selector, long value, void*, double*) | |||
| static long JUCE_ASIOCALLBACK asioMessagesCallback1 (long selector, long value, void*, double*) | |||
| { | |||
| return asioMessagesCallback (selector, value, 1); | |||
| } | |||
| static long asioMessagesCallback2 (long selector, long value, void*, double*) | |||
| static long JUCE_ASIOCALLBACK asioMessagesCallback2 (long selector, long value, void*, double*) | |||
| { | |||
| return asioMessagesCallback (selector, value, 2); | |||
| } | |||
| static long asioMessagesCallback (long selector, long value, const int deviceIndex) | |||
| static long JUCE_ASIOCALLBACK asioMessagesCallback (long selector, long value, const int deviceIndex) | |||
| { | |||
| switch (selector) | |||
| { | |||
| @@ -250606,7 +250610,7 @@ private: | |||
| return 0; | |||
| } | |||
| static void sampleRateChangedCallback (ASIOSampleRate) throw() | |||
| static void JUCE_ASIOCALLBACK sampleRateChangedCallback (ASIOSampleRate) | |||
| { | |||
| } | |||
| @@ -252708,6 +252712,8 @@ static void logFailure (HRESULT hr) | |||
| #endif | |||
| } | |||
| #undef check | |||
| static bool check (HRESULT hr) | |||
| { | |||
| logFailure (hr); | |||
| @@ -518,8 +518,10 @@ | |||
| /** This macro defines the C calling convention used as the standard for Juce calls. */ | |||
| #if JUCE_MSVC | |||
| #define JUCE_CALLTYPE __stdcall | |||
| #define JUCE_CDECL __cdecl | |||
| #else | |||
| #define JUCE_CALLTYPE | |||
| #define JUCE_CDECL | |||
| #endif | |||
| // Debugging and assertion macros | |||
| @@ -272,7 +272,7 @@ FLAC_API FLAC__bool FLAC__format_seektable_is_legal(const FLAC__StreamMetadata_S | |||
| } | |||
| /* used as the sort predicate for qsort() */ | |||
| static int seekpoint_compare_(const FLAC__StreamMetadata_SeekPoint *l, const FLAC__StreamMetadata_SeekPoint *r) | |||
| static int JUCE_CDECL seekpoint_compare_(const FLAC__StreamMetadata_SeekPoint *l, const FLAC__StreamMetadata_SeekPoint *r) | |||
| { | |||
| /* we don't just 'return l->sample_number - r->sample_number' since the result (FLAC__int64) might overflow an 'int' */ | |||
| if(l->sample_number == r->sample_number) | |||
| @@ -292,7 +292,7 @@ FLAC_API unsigned FLAC__format_seektable_sort(FLAC__StreamMetadata_SeekTable *se | |||
| FLAC__ASSERT(0 != seek_table); | |||
| /* sort the seekpoints */ | |||
| qsort(seek_table->points, seek_table->num_points, sizeof(FLAC__StreamMetadata_SeekPoint), (int (*)(const void *, const void *))seekpoint_compare_); | |||
| qsort(seek_table->points, seek_table->num_points, sizeof(FLAC__StreamMetadata_SeekPoint), (int (JUCE_CDECL *)(const void *, const void *))seekpoint_compare_); | |||
| /* uniquify the seekpoints */ | |||
| first = true; | |||
| @@ -174,7 +174,7 @@ static vorbis_info_floor *floor1_unpack (vorbis_info *vi,oggpack_buffer *opb){ | |||
| return(NULL); | |||
| } | |||
| static int icomp(const void *a,const void *b){ | |||
| static int JUCE_CDECL icomp(const void *a,const void *b){ | |||
| return(**(int **)a-**(int **)b); | |||
| } | |||
| @@ -298,7 +298,7 @@ static void cheby(float *g, int ord) { | |||
| } | |||
| } | |||
| static int comp(const void *a,const void *b){ | |||
| static int JUCE_CDECL comp(const void *a,const void *b){ | |||
| return (*(float *)a<*(float *)b)-(*(float *)a>*(float *)b); | |||
| } | |||
| @@ -1018,7 +1018,7 @@ float **_vp_quantize_couple_memo(vorbis_block *vb, | |||
| } | |||
| /* this is for per-channel noise normalization */ | |||
| static int apsort(const void *a, const void *b){ | |||
| static int JUCE_CDECL apsort(const void *a, const void *b){ | |||
| float f1=fabs(**(float**)a); | |||
| float f2=fabs(**(float**)b); | |||
| return (f1<f2)-(f1>f2); | |||
| @@ -304,7 +304,7 @@ int vorbis_book_init_encode(codebook *c,const static_codebook *s){ | |||
| return(0); | |||
| } | |||
| static int sort32a(const void *a,const void *b){ | |||
| static int JUCE_CDECL sort32a(const void *a,const void *b){ | |||
| return ( **(ogg_uint32_t **)a>**(ogg_uint32_t **)b)- | |||
| ( **(ogg_uint32_t **)a<**(ogg_uint32_t **)b); | |||
| } | |||
| @@ -42,8 +42,10 @@ | |||
| /** This macro defines the C calling convention used as the standard for Juce calls. */ | |||
| #if JUCE_MSVC | |||
| #define JUCE_CALLTYPE __stdcall | |||
| #define JUCE_CDECL __cdecl | |||
| #else | |||
| #define JUCE_CALLTYPE | |||
| #define JUCE_CDECL | |||
| #endif | |||
| //============================================================================== | |||
| @@ -110,19 +110,19 @@ namespace PNGHelpers | |||
| { | |||
| using namespace pnglibNamespace; | |||
| static void readCallback (png_structp png, png_bytep data, png_size_t length) | |||
| static void JUCE_CDECL readCallback (png_structp png, png_bytep data, png_size_t length) | |||
| { | |||
| static_cast<InputStream*> (png_get_io_ptr (png))->read (data, (int) length); | |||
| } | |||
| static void writeDataCallback (png_structp png, png_bytep data, png_size_t length) | |||
| static void JUCE_CDECL writeDataCallback (png_structp png, png_bytep data, png_size_t length) | |||
| { | |||
| static_cast<OutputStream*> (png_get_io_ptr (png))->write (data, (int) length); | |||
| } | |||
| struct PNGErrorStruct {}; | |||
| static void errorCallback (png_structp, png_const_charp) | |||
| static void JUCE_CDECL errorCallback (png_structp, png_const_charp) | |||
| { | |||
| throw PNGErrorStruct(); | |||
| } | |||
| @@ -38,6 +38,8 @@ | |||
| #define log(a) {} | |||
| #endif | |||
| #define JUCE_ASIOCALLBACK // should probably use this to define the callback type, but | |||
| // the asio header doesn't actually specify a calling convention for the functions.. | |||
| //============================================================================== | |||
| #if ASIO_DEBUGGING | |||
| @@ -1192,7 +1194,7 @@ private: | |||
| } | |||
| //============================================================================== | |||
| void callback (const long index) | |||
| void JUCE_ASIOCALLBACK callback (const long index) | |||
| { | |||
| if (isStarted) | |||
| { | |||
| @@ -1338,7 +1340,7 @@ private: | |||
| } | |||
| //============================================================================== | |||
| static ASIOTime* bufferSwitchTimeInfoCallback0 (ASIOTime*, long index, long) | |||
| static ASIOTime* JUCE_ASIOCALLBACK bufferSwitchTimeInfoCallback0 (ASIOTime*, long index, long) | |||
| { | |||
| if (currentASIODev[0] != 0) | |||
| currentASIODev[0]->callback (index); | |||
| @@ -1346,7 +1348,7 @@ private: | |||
| return 0; | |||
| } | |||
| static ASIOTime* bufferSwitchTimeInfoCallback1 (ASIOTime*, long index, long) | |||
| static ASIOTime* JUCE_ASIOCALLBACK bufferSwitchTimeInfoCallback1 (ASIOTime*, long index, long) | |||
| { | |||
| if (currentASIODev[1] != 0) | |||
| currentASIODev[1]->callback (index); | |||
| @@ -1354,7 +1356,7 @@ private: | |||
| return 0; | |||
| } | |||
| static ASIOTime* bufferSwitchTimeInfoCallback2 (ASIOTime*, long index, long) | |||
| static ASIOTime* JUCE_ASIOCALLBACK bufferSwitchTimeInfoCallback2 (ASIOTime*, long index, long) | |||
| { | |||
| if (currentASIODev[2] != 0) | |||
| currentASIODev[2]->callback (index); | |||
| @@ -1362,41 +1364,41 @@ private: | |||
| return 0; | |||
| } | |||
| static void bufferSwitchCallback0 (long index, long) | |||
| static void JUCE_ASIOCALLBACK bufferSwitchCallback0 (long index, long) | |||
| { | |||
| if (currentASIODev[0] != 0) | |||
| currentASIODev[0]->callback (index); | |||
| } | |||
| static void bufferSwitchCallback1 (long index, long) | |||
| static void JUCE_ASIOCALLBACK bufferSwitchCallback1 (long index, long) | |||
| { | |||
| if (currentASIODev[1] != 0) | |||
| currentASIODev[1]->callback (index); | |||
| } | |||
| static void bufferSwitchCallback2 (long index, long) | |||
| static void JUCE_ASIOCALLBACK bufferSwitchCallback2 (long index, long) | |||
| { | |||
| if (currentASIODev[2] != 0) | |||
| currentASIODev[2]->callback (index); | |||
| } | |||
| static long asioMessagesCallback0 (long selector, long value, void*, double*) | |||
| static long JUCE_ASIOCALLBACK asioMessagesCallback0 (long selector, long value, void*, double*) | |||
| { | |||
| return asioMessagesCallback (selector, value, 0); | |||
| } | |||
| static long asioMessagesCallback1 (long selector, long value, void*, double*) | |||
| static long JUCE_ASIOCALLBACK asioMessagesCallback1 (long selector, long value, void*, double*) | |||
| { | |||
| return asioMessagesCallback (selector, value, 1); | |||
| } | |||
| static long asioMessagesCallback2 (long selector, long value, void*, double*) | |||
| static long JUCE_ASIOCALLBACK asioMessagesCallback2 (long selector, long value, void*, double*) | |||
| { | |||
| return asioMessagesCallback (selector, value, 2); | |||
| } | |||
| //============================================================================== | |||
| static long asioMessagesCallback (long selector, long value, const int deviceIndex) | |||
| static long JUCE_ASIOCALLBACK asioMessagesCallback (long selector, long value, const int deviceIndex) | |||
| { | |||
| switch (selector) | |||
| { | |||
| @@ -1438,7 +1440,7 @@ private: | |||
| return 0; | |||
| } | |||
| static void sampleRateChangedCallback (ASIOSampleRate) throw() | |||
| static void JUCE_ASIOCALLBACK sampleRateChangedCallback (ASIOSampleRate) | |||
| { | |||
| } | |||
| @@ -82,6 +82,8 @@ static void logFailure (HRESULT hr) | |||
| #endif | |||
| } | |||
| #undef check | |||
| static bool check (HRESULT hr) | |||
| { | |||
| logFailure (hr); | |||