SoundRecognizer.StartOnMemory method |
|
Remarks
Starts recognition of a sound file stored inside a memory buffer.
For further details about the use of the sound recognizer see the SoundRecognizer object section.
For details about sound recognition refer to the How to recognize music and obtain related information tutorial.
Syntax
[Visual Basic] control.SoundRecognizer.StartOnMemory ( pBuffer as Variant, nBufferLength as Long, bWaitCompletion as enumBoolean, nUniqueId as Long ) as enumErrorCodes |
[C++] short control.SoundRecognizer.StartOnMemory ( const VARIANT FAR& pBuffer, long nBufferLength, short bWaitCompletion, long *nUniqueId ); |
Parameter |
Description |
||||||
|
|
||||||
pBuffer |
Input buffer containing the file to recognize. |
||||||
nBufferLength |
Length of the input buffer expressed in bytes. |
||||||
bWaitCompletion |
Boolean value indicating if the recognizer should wait for completion before returning to the caller. Supported values are the following:
|
||||||
nUniqueId |
Reference that, on return from the method call, will contain the unique identifier of the recognition session: in case the bWaitCompletion parameter should be set to BOOL_TRUE, this unique identifier could be immediately used in order to invoke further methods that will give access to obtained results:
- SoundRecognizer.ResultsCountGet to obtain the total number of music results - SoundRecognizer.ResultInfoGet to obtain a specific information related to the given music result - SoundRecognizer.ResultGenresCountGet to obtain the number of genres related to the given music result - SoundRecognizer.ResultGenreGet to obtain a specific genre related to the given music result - SoundRecognizer.ResultArtistsCountGet to obtain the number of artists related to the given music result - SoundRecognizer.ResultArtistInfoGet to obtain the information about the given artist - SoundRecognizer.ResultArtistRolesCountGet to obtain the number of roles related to the given artist - SoundRecognizer.ResultArtistRoleInfoGet to obtain information about the given role - SoundRecognizer.ResultsDelete to clear the given recognition session from memory |
Return value
Value |
Meaning |
|
|
Negative value |
An error occurred, check the LastError property value in order to get the error code |
enumErrorCodes.ERR_NOERROR (0) |
The method call was successful |