⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 alu.pas

📁 Newton Game Dynamic 1.52 Delphi下基于GLScene的OpenGL游戏开发控件。功能非常强大和易于使用。 Advanced physics engine for re
💻 PAS
字号:
{********************************************************************}
{ OpenAL cross platform audio library                                }
{ Copyright (C) 1999-2000 by authors.                                }
{ This library is free software; you can redistribute it and/or      }
{  modify it under the terms of the GNU Library General Public       }
{  License as published by the Free Software Foundation; either      }
{  version 2 of the License, or (at your option) any later version.  }
{                                                                    }
{ This library is distributed in the hope that it will be useful,    }
{  but WITHOUT ANY WARRANTY; without even the implied warranty of    }
{  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU }
{  Library General Public License for more details.                  }
{                                                                    }
{ You should have received a copy of the GNU Library General Public  }
{  License along with this library; if not, write to the             }
{  Free Software Foundation, Inc., 59 Temple Place - Suite 330,      }
{  Boston, MA  02111-1307, USA.                                      }
{ Or go to http://www.gnu.org/copyleft/lgpl.html                     }
{                                                                    }
{********************************************************************}

{********************************************************************}
{                                                                    }
{       Borland Delphi Runtime Library                               }
{       Copyright (c) 1995,2001 Borland International                }
{       Created by Project JEDI                                      }
{                                                                    }
{ The original Pascal code is: Alu.pas 	                             }
{ The initial developer of the Pascal code is Amresh Ramachandran    }
{                                                                    }
{ Portions created by Amresh Ramachandran are    	  			           }
{ Copyright (C) 2001 Amresh Ramachandran (amreshr@hotmail.com)       }
{                                                                    }
{ Contributor(s): Amresh Ramachandran                                }
{                                                                    }
{       Obtained through:                                            }
{                                                                    }
{       Joint Endeavour of Delphi Innovators (Project JEDI)          }
{                                                                    }
{ You may retrieve the latest version of this file at the Project    }
{ JEDI home page, located at http://delphi-jedi.org                  }
{                                                                    }
{ The contents of this file are used with permission, subject to     }
{ the Mozilla Public License Version 1.1 (the "License"); you may    }
{ not use this file except in compliance with the License. You may   }
{ obtain a copy of the License at                                    }
{ http://www.mozilla.org/MPL/MPL-1.1.html 	                         }
{                                                                    }
{ Software distributed under the License is distributed on an 	     }
{ "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or     }
{ implied. See the License for the specific language governing       }
{ rights and limitations under the License. 				                 }
{                                                                    }
{********************************************************************}

unit Alu;

{***************************************************************
 *
 * Unit Name         : Alu
 * Purpose           :
 *  This is an interface unit for the use of OpenAL from within Delphi and
 *  contains the translations of alu.h
 * Author            : Amresh Ramachandran amreshr@hotmail.com
 * Project name      : OpenAL Delphi Translation
 * Created           : 15-Oct-2001
 * History           :
 * Saturday, October 20, 2001 16:17
 * Included this header
 *
 ****************************************************************}
//------------------------------------------------------------------------------
//
//  This is an interface unit for the use of OpenAL from within Delphi and
//  contains the translations of alu.h.
//
//------------------------------------------------------------------------------

interface

uses AlTypes;

const

AL32 = 'OpenAL32.dll';

BUFFERSIZE = 48000;
FRACTIONBITS = 14;
//???????
//#define FRACTIONMASK ((1L<<FRACTIONBITS)-1)
FRACTIONMASK = ((1 shl FRACTIONBITS)-1);
OUTPUTCHANNELS = 2;

function aluF2L(value: TALfloat): TALint; cdecl; external AL32;

function aluF2S(value: TALfloat): TALshort; cdecl; external AL32;

procedure aluCrossproduct(inVector1: PALfloat; inVector2: PALfloat; outVector: PALfloat); cdecl; external AL32;

function aluDotproduct(inVector1: PALfloat; inVector2: PALfloat): TALfloat ; cdecl; external AL32;

procedure aluNormalize(inVector1: PALfloat); cdecl; external AL32;

procedure aluMatrixVector(matrix: array of TALfloat; vector: PALfloat); cdecl; external AL32;

procedure aluCalculateSourceParameters(source: TALuint; channels: TALuint; drysend: PALfloat; wetsend: PALfloat; pitch: PALfloat); cdecl; external AL32;

procedure aluMixData(context: Pointer; buffer: Pointer; size: TALsizei; format: TALenum); cdecl; external AL32;

procedure aluSetReverb(Reverb: Pointer; Environment: TALuint); cdecl; external AL32;

procedure aluReverb(Reverb: Pointer; Buffer: array of TALfloat; BufferSize: TALsizei); cdecl; external AL32;


implementation

end.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -