C# Class PlayControl.BassWrapper

Bass Wrapper Class to wrap the Bass Library
显示文件 Open project: mhack/gamenoise Class Usage Examples

Public Properties

Property Type Description
TmpBalance float

Public Methods

Method Description
BassWrapper ( IntPtr handle ) : System

Constructor for the Bass Wrapper Class

GetTags ( String songPath ) : string[]

Method to Read Music Tags from Files

GetTimeLength ( string filepath ) : double

Get The Length of a Song

drawVisual ( Graphics g ) : void

This method wraps the Visualisingmethods of the BASS Library

getBalance ( ) : float

Get The Balace

getChangeEQ ( ) : bool

Returns if something in the EQ has changed

getElapsedTime ( ) : double

Get Method for elapsed Time of Stream

getEqualizer ( ) : float[]

Get Method for recent Equalizer Settings

getFFTData ( ) : float[]

Catch the FFT-Data of the current steam

getPaused ( ) : bool

Get Method for check if Stream is paused

getStreamId ( ) : int
getTags ( String songPath ) : string[]

Method to Read Music Tags from Files

getTotalTime ( ) : double

Get Method for total Time of Stream

getVolume ( ) : float

Volume Get-Method

getstopped ( ) : bool

Get Stop Variable

gettoggleEQ ( ) : bool

Get EQ-state

pause ( ) : void

Pause the Playing stream or if it is paused Play it aggain

play ( string songPath ) : void

The Play Method plays a song by his path with the Bass Lib.

play ( string songPath, bool &validSong ) : void

The Play Method plays a song by his path with the Bass Lib.

setBalance ( float bal ) : void

Set The Balace

setEqualizer ( float frequencyList ) : void

Set Equalizer Settings

setEqualizerBand ( int band, float freq ) : void

Sets Single Equalizer Band

setPlayPosition ( double seconds ) : bool

Set A new Postition to Play the stream

setVolume ( float gain ) : void

Method to Set Volume of Master Output

settoggleEQ ( bool state ) : void

Switch Equalizer On/Off

stop ( ) : void

Stop playing stream

Private Methods

Method Description
EndSync ( int handle, int channel, int data, IntPtr user ) : void

This Method is is Called when a Song is at its end

EqualizerInit ( ) : void

This Method Sets the Equalizer Settings to a new Stream.

EtimeClockTick ( object sender, EventArgs e ) : void

Method Details

BassWrapper() public method

Constructor for the Bass Wrapper Class
public BassWrapper ( IntPtr handle ) : System
handle System.IntPtr Window Handle
return System

GetTags() public static method

Method to Read Music Tags from Files
public static GetTags ( String songPath ) : string[]
songPath String Filepath
return string[]

GetTimeLength() public static method

Get The Length of a Song
public static GetTimeLength ( string filepath ) : double
filepath string Song
return double

drawVisual() public method

This method wraps the Visualisingmethods of the BASS Library
public drawVisual ( Graphics g ) : void
g System.Drawing.Graphics Grafics Object
return void

getBalance() public method

Get The Balace
public getBalance ( ) : float
return float

getChangeEQ() public method

Returns if something in the EQ has changed
public getChangeEQ ( ) : bool
return bool

getElapsedTime() public method

Get Method for elapsed Time of Stream
public getElapsedTime ( ) : double
return double

getEqualizer() public method

Get Method for recent Equalizer Settings
public getEqualizer ( ) : float[]
return float[]

getFFTData() public method

Catch the FFT-Data of the current steam
public getFFTData ( ) : float[]
return float[]

getPaused() public method

Get Method for check if Stream is paused
public getPaused ( ) : bool
return bool

getStreamId() public method

public getStreamId ( ) : int
return int

getTags() public method

Method to Read Music Tags from Files
public getTags ( String songPath ) : string[]
songPath String
return string[]

getTotalTime() public method

Get Method for total Time of Stream
public getTotalTime ( ) : double
return double

getVolume() public method

Volume Get-Method
public getVolume ( ) : float
return float

getstopped() public method

Get Stop Variable
public getstopped ( ) : bool
return bool

gettoggleEQ() public method

Get EQ-state
public gettoggleEQ ( ) : bool
return bool

pause() public method

Pause the Playing stream or if it is paused Play it aggain
public pause ( ) : void
return void

play() public method

The Play Method plays a song by his path with the Bass Lib.
public play ( string songPath ) : void
songPath string
return void

play() public method

The Play Method plays a song by his path with the Bass Lib.
public play ( string songPath, bool &validSong ) : void
songPath string Song Path to Play
validSong bool returns if song is playable by plugin or bass
return void

setBalance() public method

Set The Balace
public setBalance ( float bal ) : void
bal float -1 left / +1 right
return void

setEqualizer() public method

Set Equalizer Settings
public setEqualizer ( float frequencyList ) : void
frequencyList float 10 Band Float list
return void

setEqualizerBand() public method

Sets Single Equalizer Band
public setEqualizerBand ( int band, float freq ) : void
band int Band to set
freq float Gain to set
return void

setPlayPosition() public method

Set A new Postition to Play the stream
public setPlayPosition ( double seconds ) : bool
seconds double Stream position
return bool

setVolume() public method

Method to Set Volume of Master Output
public setVolume ( float gain ) : void
gain float /// Volume: /// 1 = max /// 0 = min ///
return void

settoggleEQ() public method

Switch Equalizer On/Off
public settoggleEQ ( bool state ) : void
state bool /// true = On /// false = Off ///
return void

stop() public method

Stop playing stream
public stop ( ) : void
return void

Property Details

TmpBalance public_oe property

Temporary Save Balance
public float TmpBalance
return float