Version

menu_open

include/AK/Wwise/Utilities.h

Go to the documentation of this file.
00001 /*******************************************************************************
00002 The content of this file includes portions of the AUDIOKINETIC Wwise Technology
00003 released in source code form as part of the SDK installer package.
00004 
00005 Commercial License Usage
00006 
00007 Licensees holding valid commercial licenses to the AUDIOKINETIC Wwise Technology
00008 may use this file in accordance with the end user license agreement provided 
00009 with the software or, alternatively, in accordance with the terms contained in a
00010 written agreement between you and Audiokinetic Inc.
00011 
00012 Apache License Usage
00013 
00014 Alternatively, this file may be used under the Apache License, Version 2.0 (the 
00015 "Apache License"); you may not use this file except in compliance with the 
00016 Apache License. You may obtain a copy of the Apache License at 
00017 http://www.apache.org/licenses/LICENSE-2.0.
00018 
00019 Unless required by applicable law or agreed to in writing, software distributed
00020 under the Apache License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES
00021 OR CONDITIONS OF ANY KIND, either express or implied. See the Apache License for
00022 the specific language governing permissions and limitations under the License.
00023 
00024   Version: <VERSION>  Build: <BUILDNUMBER>
00025   Copyright (c) <COPYRIGHTYEAR> Audiokinetic Inc.
00026 *******************************************************************************/
00027 
00030 
00031 #ifndef _AK_WWISE_UTILITIES_H
00032 #define _AK_WWISE_UTILITIES_H
00033 
00034 #include <AK/SoundEngine/Common/AkTypes.h>
00035 
00037 // Populate Table macros
00039 
00050 #define AK_BEGIN_POPULATE_TABLE(theName) AK::Wwise::PopulateTableItem theName[] = {
00051 
00064 #define AK_POP_ITEM(theID, theProp) {theID, theProp },
00065 
00072 #define AK_END_POPULATE_TABLE() AK_POP_ITEM(0, NULL) };
00073 
00075 // Utilities
00077 
00078 // Audiokinetic namespace
00079 namespace AK
00080 {
00081     // Audiokinetic Wwise namespace
00082     namespace Wwise
00083     {
00085         enum AudioFileChannel
00086         {
00087             Channel_mono        = 0,
00088             Channel_stereo      = 1,
00089             Channel_mono_drop   = 2,
00090             Channel_stereo_drop = 3,
00091             Channel_as_input    = 4,
00092             Channel_mono_drop_right = 5,
00093             Channel_stereo_balance  = 6,
00094         };
00095 
00097         enum LicenseType
00098         {
00099             LicenseType_Trial = 1, 
00100             LicenseType_Purchased,
00101             LicenseType_Academic
00102         };
00103 
00105         enum LicenseStatus
00106         {
00107             LicenseStatus_Unlicensed,
00108             LicenseStatus_Expired,
00109             LicenseStatus_Valid,
00110 
00111             LicenseStatus_Incompatible      //the plugin is for an older version of wwise
00112         };
00113 
00115         enum Severity
00116         {
00117             Severity_Success = -1,  
00118             Severity_Message,       
00119             Severity_Warning,       
00120             Severity_Error,         
00121             Severity_FatalError,    
00122                     
00123         };
00124 
00127         class IWriteString
00128         {
00129         public:
00130             virtual void WriteString( LPCWSTR in_szString, 
00131                                         int in_iStringLength ) = 0;
00132         };
00133 
00135         class IReadOnlyProperties 
00136         {
00137         public:
00138             virtual bool GetValue( LPCWSTR in_szPropertyName, 
00139                                     VARIANT& out_rValue ) const = 0;
00140         };
00141 
00142         class IReadWriteProperties : public IReadOnlyProperties
00143         {
00144         public:
00145             virtual bool SetValue( LPCWSTR in_szPropertyName, 
00146                                         const VARIANT& in_rValue ) = 0;
00147         };
00148 
00149         class IProgress
00150         {
00151         public: 
00155             virtual void SetCurrentOperationName( LPCWSTR in_szOperationName ) = 0;
00156 
00158             virtual void SetRange( DWORD in_dwMinValue, DWORD in_dwMaxValue ) = 0;
00159 
00161             virtual void NotifyProgress( DWORD in_dwProgress ) = 0;
00162 
00164             virtual bool IsCancelled() = 0;
00165 
00168             virtual void ErrorMessage( const CString& in_rErrorText, Severity in_eSeverity = Severity_Warning ) = 0;
00169         };
00170 
00172         class IDoubleProgress : public IProgress
00173         {
00174         public:
00178             virtual void SetSecondOperationName( LPCWSTR in_szOperationName ) = 0;
00179 
00182             virtual void SetSecondRange( DWORD in_dwMinValue, DWORD in_dwMaxValue ) = 0;
00183 
00185             virtual void NotifySecondProgress( DWORD in_dwProgress ) = 0;
00186         };
00187 
00196         struct PopulateTableItem
00197         {
00198             UINT uiID;              
00199             LPCWSTR pszProp;        
00200         };
00201 
00206         class IPluginBase
00207         {
00208         public:
00214             virtual void Destroy() = 0;
00215         };
00216 
00218         enum ConversionResult
00219         {
00220             ConversionSuccess           = 0,
00221             ConversionWarning           = 1,
00222             ConversionFailed            = 2,
00223         };
00224 
00235         class IWriteData
00236         {
00237         public:
00242             virtual bool WriteData(
00243                 LPCVOID in_pData,           
00244                 UINT32 in_cBytes,           
00245                 UINT32 & out_cWritten       
00246             ) = 0;
00247 
00263             virtual bool WritePascalString(
00264                 LPCWSTR in_szString,        
00265                 UINT32 in_uiStringLength    
00266             ) = 0;
00267 
00278             virtual bool WriteUtf16String(
00279                 LPCWSTR in_szString         
00280             ) = 0;
00281 
00284             virtual bool WriteUtf8String(
00285                 const char * in_szString        
00286             ) = 0;
00287 
00290             virtual bool WriteBool(
00291                 bool in_bBool               
00292             ) = 0;
00293 
00296             virtual bool WriteByte(
00297                 BYTE in_bByte               
00298             ) = 0;
00299 
00302             virtual bool WriteInt16(
00303                 UINT16 in_uiInt16           
00304             ) = 0;
00305 
00308             virtual bool WriteInt32(
00309                 UINT32 in_uiInt32           
00310             ) = 0;
00311 
00314             virtual bool WriteInt64(
00315                 UINT64 in_uiInt64           
00316             ) = 0;
00317 
00320             virtual bool WriteReal32(
00321                 float in_fReal32            
00322             ) = 0;
00323 
00326             virtual bool WriteReal64(
00327                 double in_dblReal64         
00328             ) = 0;
00329         };
00330     }
00331 }
00332 
00333 #endif // _WWISE_UTILITIES_H

Was this page helpful?

Need Support?

Questions? Problems? Need more info? Contact us, and we can help!

Visit our Support page

Tell us about your project. We're here to help.

Register your project and we'll help you get started with no strings attached!

Get started with Wwise