mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-09 23:34:20 +00:00
ASIO: Bundle required headers from SDK
This commit is contained in:
parent
bd5e4415f9
commit
89fc608a34
8 changed files with 1324 additions and 24 deletions
|
|
@ -1,5 +1,31 @@
|
|||
# JUCE breaking changes
|
||||
|
||||
# develop
|
||||
|
||||
## Change
|
||||
|
||||
Enabling JUCE_ASIO will now default to using bundled ASIO sources.
|
||||
|
||||
**Possible Issues**
|
||||
|
||||
Programs that depend on specific versions of the ASIO SDK (perhaps with custom
|
||||
modifications) may be broken.
|
||||
|
||||
**Workaround**
|
||||
|
||||
To use a different version of the ASIO SDK, additionally set the
|
||||
JUCE_ASIO_USE_EXTERNAL_SDK module option. If you're happy to use the bundled
|
||||
sources, consider removing the custom header include paths you were previously
|
||||
using to locate the ASIO headers.
|
||||
|
||||
**Rationale**
|
||||
|
||||
The bundled headers should be sufficient for the majority of use-cases, so this
|
||||
is now the standard option requiring less configuration. Using custom headers
|
||||
is an advanced use-case, so it's reasonable that this requires some additional
|
||||
configuration, i.e. setting the JUCE_ASIO_USE_EXTERNAL_SDK flag.
|
||||
|
||||
|
||||
# Version 8.0.9
|
||||
|
||||
## Change
|
||||
|
|
|
|||
|
|
@ -52,6 +52,7 @@ The JUCE modules contain the following dependencies:
|
|||
- [zlib](modules/juce_core/zip/zlib/) ([zlib](modules/juce_core/zip/zlib/README))
|
||||
- [HarfBuzz](modules/juce_graphics/fonts/harfbuzz/) ([Old MIT](modules/juce_graphics/fonts/harfbuzz/COPYING))
|
||||
- [SheenBidi](modules/juce_graphics/unicode/sheenbidi/) ([Apache](modules/juce_graphics/unicode/sheenbidi/LICENSE))
|
||||
- [ASIO](modules/juce_audio_devices/native/asio/) ([Proprietary Steinberg ASIO License/GPLv3](modules/juce_audio_devices/native/asio/LICENSE.txt))
|
||||
|
||||
The JUCE examples are licensed under the terms of the
|
||||
[ISC license](http://www.isc.org/downloads/software-support-policy/isc-license/).
|
||||
|
|
|
|||
|
|
@ -136,26 +136,11 @@
|
|||
#endif
|
||||
|
||||
#if JUCE_ASIO
|
||||
/* This is very frustrating - we only need to use a handful of definitions from
|
||||
a couple of the header files in Steinberg's ASIO SDK, and it'd be easy to copy
|
||||
about 30 lines of code into this cpp file to create a fully stand-alone ASIO
|
||||
implementation...
|
||||
|
||||
..unfortunately that would break Steinberg's license agreement for use of
|
||||
their SDK, so I'm not allowed to do this.
|
||||
|
||||
This means that anyone who wants to use JUCE's ASIO abilities will have to:
|
||||
|
||||
1) Agree to Steinberg's licensing terms and download the ASIO SDK
|
||||
(see http://www.steinberg.net/en/company/developers.html).
|
||||
|
||||
2) Enable this code with a global definition #define JUCE_ASIO 1.
|
||||
|
||||
3) Make sure that your header search path contains the iasiodrv.h file that
|
||||
comes with the SDK. (Only about a handful of the SDK header files are actually
|
||||
needed - so to simplify things, you could just copy these into your JUCE directory).
|
||||
*/
|
||||
#if JUCE_ASIO_USE_EXTERNAL_SDK
|
||||
#include <iasiodrv.h>
|
||||
#else
|
||||
#include <juce_audio_devices/native/asio/iasiodrv.h>
|
||||
#endif
|
||||
#include "native/juce_ASIO_windows.cpp"
|
||||
#endif
|
||||
|
||||
|
|
|
|||
|
|
@ -123,16 +123,31 @@
|
|||
|
||||
/** Config: JUCE_ASIO
|
||||
Enables ASIO audio devices (MS Windows only).
|
||||
Turning this on means that you'll need to have the Steinberg ASIO SDK installed
|
||||
on your Windows build machine.
|
||||
IMPORTANT: Turning this on will cause your program to depend on source files
|
||||
from the ASIO SDK from Steinberg, so your resulting program must adhere to
|
||||
the license terms of those files.
|
||||
|
||||
See the comments in the ASIOAudioIODevice class's header file for more
|
||||
info about this.
|
||||
By default, this option will use the bundled ASIO headers distributed
|
||||
alongside JUCE. See the documentation for JUCE_ASIO_USE_EXTERNAL_SDK to
|
||||
learn how to use a different version of those headers.
|
||||
*/
|
||||
#ifndef JUCE_ASIO
|
||||
#define JUCE_ASIO 0
|
||||
#endif
|
||||
|
||||
/** Config: JUCE_ASIO_USE_EXTERNAL_SDK
|
||||
The default behaviour of the JUCE_ASIO flag is to include a bundled header
|
||||
from the ASIO SDK. If you need to supply your own version of this header,
|
||||
instead of using the bundled one, you can enable this flag. If you do,
|
||||
then you must also ensure that the file "iasiodrv.h" from the SDK can be
|
||||
located via your project's header include paths.
|
||||
|
||||
The option only has an effect when JUCE_ASIO is also enabled.
|
||||
*/
|
||||
#ifndef JUCE_ASIO_USE_EXTERNAL_SDK
|
||||
#define JUCE_ASIO_USE_EXTERNAL_SDK 0
|
||||
#endif
|
||||
|
||||
/** Config: JUCE_WASAPI
|
||||
Enables WASAPI audio devices (Windows Vista and above).
|
||||
*/
|
||||
|
|
|
|||
45
modules/juce_audio_devices/native/asio/LICENSE.txt
Normal file
45
modules/juce_audio_devices/native/asio/LICENSE.txt
Normal file
|
|
@ -0,0 +1,45 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
// LICENSE
|
||||
// (c) 2025, Steinberg Media Technologies GmbH, All Rights Reserved
|
||||
//-----------------------------------------------------------------------------
|
||||
This license applies only to files referencing this license,
|
||||
for other files of the Software Development Kit the respective embedded license text
|
||||
is applicable.
|
||||
|
||||
This Software Development Kit is licensed under the terms of the Steinberg ASIO License,
|
||||
or alternatively under the terms of the General Public License (GPL) Version 3.
|
||||
You may use the Software Development Kit according to either of these licenses as it is
|
||||
most appropriate for your project on a case-by-case basis (commercial or not).
|
||||
|
||||
a) Proprietary Steinberg ASIO License
|
||||
The Software Development Kit may not be distributed in parts or its entirety
|
||||
without prior written agreement by Steinberg Media Technologies GmbH.
|
||||
The SDK must not be used to re-engineer or manipulate any technology used
|
||||
in any Steinberg or Third-party application or software module,
|
||||
unless permitted by law.
|
||||
Neither the name of the Steinberg Media Technologies GmbH nor the names of its
|
||||
contributors may be used to endorse or promote products derived from this
|
||||
software without specific prior written permission.
|
||||
Before publishing a software under the proprietary license, you need to obtain a copy
|
||||
of the License Agreement signed by Steinberg Media Technologies GmbH.
|
||||
The Steinberg ASIO SDK License Agreement can be found at:
|
||||
www.steinberg.net/en/company/developers.html
|
||||
|
||||
THE SDK IS PROVIDED BY STEINBERG MEDIA TECHNOLOGIES GMBH "AS IS" AND
|
||||
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
|
||||
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
IN NO EVENT SHALL STEINBERG MEDIA TECHNOLOGIES GMBH BE LIABLE FOR ANY DIRECT,
|
||||
INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
|
||||
BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
|
||||
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
|
||||
OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
|
||||
OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
b) General Public License (GPL) Version 3
|
||||
Details of these licenses can be found at: www.gnu.org/licenses/gpl-3.0.html
|
||||
|
||||
Best Practice recommendation:
|
||||
Please refer to the Steinberg ASIO usage guidelines for the use of ASIO, ASIO logo and ASIO
|
||||
compatible logos.
|
||||
//----------------------------------------------------------------------------------
|
||||
1078
modules/juce_audio_devices/native/asio/asio.h
Normal file
1078
modules/juce_audio_devices/native/asio/asio.h
Normal file
File diff suppressed because it is too large
Load diff
97
modules/juce_audio_devices/native/asio/asiosys.h
Normal file
97
modules/juce_audio_devices/native/asio/asiosys.h
Normal file
|
|
@ -0,0 +1,97 @@
|
|||
//------------------------------------------------------------------------
|
||||
// Project : ASIO SDK
|
||||
//
|
||||
// Category : Interfaces
|
||||
// Filename : common/asiosys.h
|
||||
// Created by : Steinberg, 05/1996
|
||||
// Description : Steinberg Audio Stream I/O
|
||||
//
|
||||
//-----------------------------------------------------------------------------
|
||||
// This file is part of a Steinberg SDK. It is subject to the license terms
|
||||
// in the LICENSE file found in the top-level directory of this distribution
|
||||
// and at www.steinberg.net/sdklicenses.
|
||||
// No part of the SDK, including this file, may be copied, modified, propagated,
|
||||
// or distributed except according to the terms contained in the LICENSE file.
|
||||
//-----------------------------------------------------------------------------
|
||||
|
||||
#ifndef __asiosys__
|
||||
#define __asiosys__
|
||||
|
||||
#if defined(_WIN32) || defined(_WIN64)
|
||||
#undef MAC
|
||||
#define PPC 0
|
||||
#define WINDOWS 1
|
||||
#define SGI 0
|
||||
#define SUN 0
|
||||
#define LINUX 0
|
||||
#define BEOS 0
|
||||
|
||||
#define NATIVE_INT64 0
|
||||
#define IEEE754_64FLOAT 1
|
||||
|
||||
#elif BEOS
|
||||
#define MAC 0
|
||||
#define PPC 0
|
||||
#define WINDOWS 0
|
||||
#define PC 0
|
||||
#define SGI 0
|
||||
#define SUN 0
|
||||
#define LINUX 0
|
||||
|
||||
#define NATIVE_INT64 0
|
||||
#define IEEE754_64FLOAT 1
|
||||
|
||||
#ifndef DEBUG
|
||||
#define DEBUG 0
|
||||
#if DEBUG
|
||||
void DEBUGGERMESSAGE(char *string);
|
||||
#else
|
||||
#define DEBUGGERMESSAGE(a)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#elif SGI
|
||||
#define MAC 0
|
||||
#define PPC 0
|
||||
#define WINDOWS 0
|
||||
#define PC 0
|
||||
#define SUN 0
|
||||
#define LINUX 0
|
||||
#define BEOS 0
|
||||
|
||||
#define NATIVE_INT64 0
|
||||
#define IEEE754_64FLOAT 1
|
||||
|
||||
#ifndef DEBUG
|
||||
#define DEBUG 0
|
||||
#if DEBUG
|
||||
void DEBUGGERMESSAGE(char *string);
|
||||
#else
|
||||
#define DEBUGGERMESSAGE(a)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#else // MAC
|
||||
#define MAC 1
|
||||
#define PPC 1
|
||||
#define WINDOWS 0
|
||||
#define PC 0
|
||||
#define SGI 0
|
||||
#define SUN 0
|
||||
#define LINUX 0
|
||||
#define BEOS 0
|
||||
|
||||
#define NATIVE_INT64 0
|
||||
#define IEEE754_64FLOAT 1
|
||||
|
||||
#ifndef DEBUG
|
||||
#define DEBUG 0
|
||||
#if DEBUG
|
||||
void DEBUGGERMESSAGE(char *string);
|
||||
#else
|
||||
#define DEBUGGERMESSAGE(a)
|
||||
#endif
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#endif
|
||||
53
modules/juce_audio_devices/native/asio/iasiodrv.h
Normal file
53
modules/juce_audio_devices/native/asio/iasiodrv.h
Normal file
|
|
@ -0,0 +1,53 @@
|
|||
//------------------------------------------------------------------------
|
||||
// Project : ASIO SDK
|
||||
//
|
||||
// Category : Interfaces
|
||||
// Filename : common/iasiodrv.h
|
||||
// Created by : Steinberg, 05/1996
|
||||
// Description : Steinberg Audio Stream I/O API v2.3
|
||||
//
|
||||
//-----------------------------------------------------------------------------
|
||||
// This file is part of a Steinberg SDK. It is subject to the license terms
|
||||
// in the LICENSE file found in the top-level directory of this distribution
|
||||
// and at www.steinberg.net/sdklicenses.
|
||||
// No part of the SDK, including this file, may be copied, modified, propagated,
|
||||
// or distributed except according to the terms contained in the LICENSE file.
|
||||
//-----------------------------------------------------------------------------
|
||||
|
||||
#include "asiosys.h"
|
||||
#include "asio.h"
|
||||
|
||||
/* Forward Declarations */
|
||||
|
||||
#ifndef __ASIODRIVER_FWD_DEFINED__
|
||||
#define __ASIODRIVER_FWD_DEFINED__
|
||||
typedef interface IASIO IASIO;
|
||||
#endif /* __ASIODRIVER_FWD_DEFINED__ */
|
||||
|
||||
interface IASIO : public IUnknown
|
||||
{
|
||||
|
||||
virtual ASIOBool init(void *sysHandle) = 0;
|
||||
virtual void getDriverName(char *name) = 0;
|
||||
virtual long getDriverVersion() = 0;
|
||||
virtual void getErrorMessage(char *string) = 0;
|
||||
virtual ASIOError start() = 0;
|
||||
virtual ASIOError stop() = 0;
|
||||
virtual ASIOError getChannels(long *numInputChannels, long *numOutputChannels) = 0;
|
||||
virtual ASIOError getLatencies(long *inputLatency, long *outputLatency) = 0;
|
||||
virtual ASIOError getBufferSize(long *minSize, long *maxSize,
|
||||
long *preferredSize, long *granularity) = 0;
|
||||
virtual ASIOError canSampleRate(ASIOSampleRate sampleRate) = 0;
|
||||
virtual ASIOError getSampleRate(ASIOSampleRate *sampleRate) = 0;
|
||||
virtual ASIOError setSampleRate(ASIOSampleRate sampleRate) = 0;
|
||||
virtual ASIOError getClockSources(ASIOClockSource *clocks, long *numSources) = 0;
|
||||
virtual ASIOError setClockSource(long reference) = 0;
|
||||
virtual ASIOError getSamplePosition(ASIOSamples *sPos, ASIOTimeStamp *tStamp) = 0;
|
||||
virtual ASIOError getChannelInfo(ASIOChannelInfo *info) = 0;
|
||||
virtual ASIOError createBuffers(ASIOBufferInfo *bufferInfos, long numChannels,
|
||||
long bufferSize, ASIOCallbacks *callbacks) = 0;
|
||||
virtual ASIOError disposeBuffers() = 0;
|
||||
virtual ASIOError controlPanel() = 0;
|
||||
virtual ASIOError future(long selector,void *opt) = 0;
|
||||
virtual ASIOError outputReady() = 0;
|
||||
};
|
||||
Loading…
Add table
Add a link
Reference in a new issue