/[pcsx2_0.9.7]/trunk/3rdparty/portaudio/src/hostapi/asio/ASIO-README.txt
ViewVC logotype

Contents of /trunk/3rdparty/portaudio/src/hostapi/asio/ASIO-README.txt

Parent Directory Parent Directory | Revision Log Revision Log


Revision 273 - (show annotations) (download)
Fri Nov 12 01:10:22 2010 UTC (9 years, 2 months ago) by william
File MIME type: text/plain
File size: 4576 byte(s)
Auto Commited Import of: pcsx2-0.9.7-DEBUG (upstream: v0.9.7.4013 local: v0.9.7.197-latest) in ./trunk
1 ASIO-README.txt
2
3 This document contains information to help you compile PortAudio with
4 ASIO support. If you find any omissions or errors in this document
5 please notify us on the PortAudio mailing list.
6
7
8 Building PortAudio with ASIO support
9 ------------------------------------
10
11 To build PortAudio with ASIO support you need to compile and link with
12 pa_asio.c, and files from the ASIO SDK (see below), along with the common
13 files from src/common/ and platform specific files from src/os/win/ (for Win32)
14 or src/os/mac/ (for Macintosh).
15
16 If you are compiling with a non-Microsoft compiler on Windows, also
17 compile and link with iasiothiscallresolver.cpp (see below for
18 an explanation).
19
20 For some platforms (MingW, possibly Mac), you may simply
21 be able to type:
22
23 ./configure --with-host_os=mingw --with-winapi=asio [--with-asiodir=/usr/local/asiosdk2]
24 make
25
26 ./configure --with-host_os=darwin --with-winapi=asio [--with-asiodir=/usr/local/asiosdk2]
27 make
28
29 and life will be good.
30
31
32 Obtaining the ASIO SDK
33 ----------------------
34
35 In order to build PortAudio with ASIO support, you need to download
36 the ASIO SDK (version 2.0) from Steinberg. Steinberg makes the ASIO
37 SDK available to anyone free of charge, however they do not permit its
38 source code to be distributed.
39
40 NOTE: In some cases the ASIO SDK may require patching, see below
41 for further details.
42
43 http://www.steinberg.de/329+M52087573ab0.html
44
45 If the above link is broken search Google for:
46 "download steinberg ASIO SDK"
47
48
49
50 Building the ASIO SDK on Macintosh
51 ----------------------------------
52
53 To build the ASIO SDK on Macintosh you need to compile and link with the
54 following files from the ASIO SDK:
55
56 host/asiodrivers.cpp
57 host/mac/asioshlib.cpp
58 host/mac/codefragements.cpp
59
60 You may also need to adjust your include paths to support inclusion of
61 header files from the above directories.
62
63
64
65 Building the ASIO SDK on Windows
66 --------------------------------
67
68 To build the ASIO SDK on Windows you need to compile and link with the
69 following files from the ASIO SDK:
70
71 asio_sdk\common\asio.cpp
72 asio_sdk\host\asiodrivers.cpp
73 asio_sdk\host\pc\asiolist.cpp
74
75 You may also need to adjust your include paths to support inclusion of
76 header files from the above directories.
77
78 The ASIO SDK depends on the following COM API functions:
79 CoInitialize, CoUninitialize, CoCreateInstance, CLSIDFromString
80 For compilation with MinGW you will need to link with -lole32, for
81 Borland compilers link with Import32.lib.
82
83
84
85 Non-Microsoft (MSVC) Compilers on Windows including Borland and GCC
86 -------------------------------------------------------------------
87
88 Steinberg did not specify a calling convention in the IASIO interface
89 definition. This causes the Microsoft compiler to use the proprietary
90 thiscall convention which is not compatible with other compilers, such
91 as compilers from Borland (BCC and C++Builder) and GNU (gcc).
92 Steinberg's ASIO SDK will compile but crash on initialization if
93 compiled with a non-Microsoft compiler on Windows.
94
95 PortAudio solves this problem using the iasiothiscallresolver library
96 which is included in the distribution. When building ASIO support for
97 non-Microsoft compilers, be sure to compile and link with
98 iasiothiscallresolver.cpp. Note that iasiothiscallresolver includes
99 conditional directives which cause it to have no effect if it is
100 compiled with a Microsoft compiler, or on the Macintosh.
101
102 If you use configure and make (see above), this should be handled
103 automatically for you.
104
105 For further information about the IASIO thiscall problem see this page:
106 http://www.audiomulch.com/~rossb/code/calliasio
107
108
109
110 Macintosh ASIO SDK Bug Patch
111 ----------------------------
112
113 There is a bug in the ASIO SDK that causes the Macintosh version to
114 often fail during initialization. Below is a patch that you can apply.
115
116 In codefragments.cpp replace getFrontProcessDirectory function with
117 the following one (GetFrontProcess replaced by GetCurrentProcess).
118
119
120 bool CodeFragments::getFrontProcessDirectory(void *specs)
121 {
122 FSSpec *fss = (FSSpec *)specs;
123 ProcessInfoRec pif;
124 ProcessSerialNumber psn;
125
126 memset(&psn,0,(long)sizeof(ProcessSerialNumber));
127 // if(GetFrontProcess(&psn) == noErr) // wrong !!!
128 if(GetCurrentProcess(&psn) == noErr) // correct !!!
129 {
130 pif.processName = 0;
131 pif.processAppSpec = fss;
132 pif.processInfoLength = sizeof(ProcessInfoRec);
133 if(GetProcessInformation(&psn, &pif) == noErr)
134 return true;
135 }
136 return false;
137 }
138
139
140 ---

  ViewVC Help
Powered by ViewVC 1.1.22