mirror of
https://github.com/clangen/musikcube.git
synced 2025-02-11 18:40:28 +00:00
Upgraded mpg123 to 1.23.8 for Win32 build. Now built from source and
doesn't require libgcc_s_sjlj-1 or the external libmpg123-0.dll.
This commit is contained in:
parent
bdd8679865
commit
99f87237da
@ -37,10 +37,6 @@
|
||||
#include <core/sdk/IDecoder.h>
|
||||
#include <core/sdk/IDataStream.h>
|
||||
|
||||
#ifdef _MSC_VER /* ehh */
|
||||
typedef long ssize_t;
|
||||
#endif
|
||||
|
||||
#include <mpg123.h>
|
||||
|
||||
class Mpg123Decoder : public musik::core::sdk::IDecoder {
|
||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
src/contrib/mpg123decoder/bin/libmpg123.lib
Normal file
BIN
src/contrib/mpg123decoder/bin/libmpg123.lib
Normal file
Binary file not shown.
BIN
src/contrib/mpg123decoder/bin/libmpg123d.lib
Normal file
BIN
src/contrib/mpg123decoder/bin/libmpg123d.lib
Normal file
Binary file not shown.
@ -1,5 +1,5 @@
|
||||
/*
|
||||
libmpg123: MPEG Audio Decoder library (version 1.23.0)
|
||||
libmpg123: MPEG Audio Decoder library (version 1.23.8)
|
||||
|
||||
copyright 1995-2015 by the mpg123 project
|
||||
free software under the terms of the LGPL 2.1
|
||||
@ -19,6 +19,7 @@
|
||||
*/
|
||||
#define MPG123_API_VERSION 42
|
||||
|
||||
#ifndef MPG123_EXPORT
|
||||
/** Defines needed for MS Visual Studio(tm) DLL builds.
|
||||
* Every public function must be prefixed with MPG123_EXPORT. When building
|
||||
* the DLL ensure to define BUILD_MPG123_DLL. This makes the function accessible
|
||||
@ -38,6 +39,13 @@
|
||||
#define MPG123_EXPORT
|
||||
#endif
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/* This is for Visual Studio, so this header works as distributed in the binary downloads */
|
||||
#if defined(_MSC_VER)
|
||||
#include <stddef.h>
|
||||
typedef ptrdiff_t ssize_t;
|
||||
#endif
|
||||
|
||||
#ifndef MPG123_NO_CONFIGURE /* Enable use of this file without configure. */
|
||||
#include <stdlib.h>
|
||||
@ -391,7 +399,7 @@ MPG123_EXPORT int mpg123_decoder(mpg123_handle *mh, const char* decoder_name);
|
||||
* The active decoder engine can vary depening on output constraints,
|
||||
* mostly non-resampling, integer output is accelerated via 3DNow & Co. but for
|
||||
* other modes a fallback engine kicks in.
|
||||
* Note that this can return a decoder that is ony active in the hidden and not
|
||||
* Note that this can return a decoder that is only active in the hidden and not
|
||||
* available as decoder choice from the outside.
|
||||
* \param mh handle
|
||||
* \return The decoder name or NULL on error.
|
||||
@ -1097,7 +1105,7 @@ MPG123_EXPORT enum mpg123_text_encoding mpg123_enc_from_id3(unsigned char id3_en
|
||||
* Also, you might want to take a bit of care with preparing the data; for example, strip leading zeroes (I have seen that).
|
||||
* \param sb target string
|
||||
* \param enc mpg123 text encoding value
|
||||
* \param source source buffer with plain unsigned bytes (you might need to cast from char *)
|
||||
* \param source source buffer with plain unsigned bytes (you might need to cast from signed char)
|
||||
* \param source_size number of bytes in the source buffer
|
||||
* \return 0 on error, 1 on success (on error, mpg123_free_string is called on sb)
|
||||
*/
|
||||
@ -1387,7 +1395,7 @@ MPG123_EXPORT int mpg123_replace_reader( mpg123_handle *mh
|
||||
* Note: As it would be troublesome to mess with this while having a file open,
|
||||
* this mpg123_close() is implied here.
|
||||
* \param mh handle
|
||||
* \param r_read callback for reading (behaviour like POSIXread)
|
||||
* \param r_read callback for reading (behaviour like POSIX read)
|
||||
* \param r_lseek callback for seeking (like POSIX lseek)
|
||||
* \param cleanup A callback to clean up an I/O handle on mpg123_close,
|
||||
* can be NULL for none (you take care of cleaning your handles).
|
||||
@ -1404,6 +1412,4 @@ MPG123_EXPORT int mpg123_replace_reader_handle( mpg123_handle *mh
|
||||
}
|
||||
#endif
|
||||
|
||||
#undef MPG123_EXPORT
|
||||
|
||||
#endif
|
||||
|
@ -31,6 +31,7 @@
|
||||
*/
|
||||
#define OUT123_API_VERSION 1
|
||||
|
||||
#ifndef MPG123_EXPORT
|
||||
/** Defines needed for MS Visual Studio(tm) DLL builds.
|
||||
* Every public function must be prefixed with MPG123_EXPORT. When building
|
||||
* the DLL ensure to define BUILD_MPG123_DLL. This makes the function accessible
|
||||
@ -50,6 +51,7 @@
|
||||
#define MPG123_EXPORT
|
||||
#endif
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
@ -118,7 +120,7 @@ enum out123_flags
|
||||
OUT123_HEADPHONES = 0x01 /**< output to headphones (if supported) */
|
||||
, OUT123_INTERNAL_SPEAKER = 0x02 /**< output to speaker (if supported) */
|
||||
, OUT123_LINE_OUT = 0x04 /**< output to line out (if supported) */
|
||||
, OUT123_QUIET = 0x08 /**< no printouts to stdandard error */
|
||||
, OUT123_QUIET = 0x08 /**< no printouts to standard error */
|
||||
, OUT123_KEEP_PLAYING = 0x10 /**<
|
||||
* When this is set (default), playback continues in a loop when the device
|
||||
* does not consume all given data at once. This happens when encountering
|
||||
@ -182,6 +184,7 @@ enum out123_error
|
||||
, OUT123_ARG_ERROR /**< some bad function arguments supplied */
|
||||
, OUT123_BAD_PARAM /**< unknown parameter code */
|
||||
, OUT123_SET_RO_PARAM /**< attempt to set read-only parameter */
|
||||
, OUT123_BAD_HANDLE /**< bad handle pointer (NULL, usually) */
|
||||
, OUT123_ERRCOUNT /**< placeholder for shaping arrays */
|
||||
};
|
||||
|
||||
@ -194,6 +197,8 @@ MPG123_EXPORT
|
||||
const char* out123_strerror(out123_handle *ao);
|
||||
|
||||
/** Get the plain errcode intead of a string.
|
||||
* Note that this used to return OUT123_ERR instead of
|
||||
* OUT123_BAD_HANDLE in case of ao==NULL before mpg123-1.23.5 .
|
||||
* \param ao handle
|
||||
* \return error code recorded in handle or OUT123_BAD_HANDLE
|
||||
*/
|
||||
@ -574,7 +579,5 @@ int out123_getformat( out123_handle *ao
|
||||
}
|
||||
#endif
|
||||
|
||||
#undef MPG123_EXPORT
|
||||
|
||||
#endif
|
||||
|
||||
|
@ -68,12 +68,13 @@
|
||||
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>shlwapi.lib;libmpg123.dll.a;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>shlwapi.lib;libmpg123d.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>./bin;../../3rdparty/lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
<PostBuildEvent>
|
||||
<Command>xcopy /Y $(ProjectDir)bin\*.dll $(OutDir)</Command>
|
||||
<Command>
|
||||
</Command>
|
||||
</PostBuildEvent>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
@ -88,14 +89,15 @@
|
||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>shlwapi.lib;libmpg123.dll.a;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>shlwapi.lib;libmpg123.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>./bin;../../3rdparty/lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<GenerateDebugInformation>false</GenerateDebugInformation>
|
||||
</Link>
|
||||
<PostBuildEvent>
|
||||
<Command>xcopy /Y $(ProjectDir)bin\*.dll $(OutDir)</Command>
|
||||
<Command>
|
||||
</Command>
|
||||
</PostBuildEvent>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
|
@ -51,7 +51,7 @@ BOOL APIENTRY DllMain(HMODULE hModule, DWORD ul_reason_for_call, LPVOID lpReserv
|
||||
class Mpg123Plugin : public musik::core::sdk::IPlugin {
|
||||
virtual void Destroy() { delete this; }
|
||||
virtual const char* Name() { return "mpg123 IDecoder"; }
|
||||
virtual const char* Version() { return "0.3"; }
|
||||
virtual const char* Version() { return "0.4"; }
|
||||
virtual const char* Author() { return "Daniel Önnerby, clangen"; }
|
||||
};
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user