Copyright © 2005-2023 MultiMedia Soft

SoundRecognizerDone event

Previous pageReturn to chapter overviewNext page

Remarks

 

Occurs when a sound recognition session, started through one of the following methods, is completed:

 

SoundRecognizer.StartOnPlayer

SoundRecognizer.StartOnFile

SoundRecognizer.StartOnMemory

SoundRecognizer.StartOnWasapiDevice

 

For further details about synchronization through Events see the How to synchronize the container application through events tutorial.

 

 

Syntax

 

[Visual Basic]

Public Event SoundRecognizerDone As SoundRecognizerDoneEventHandler


 

[C#]

public event SoundRecognizerDoneEventHandler SoundRecognizerDone;


 

[C++]

public: __event SoundRecognizerDoneEventHandler* SoundRecognizerDone;


 

 

Event Data

 

The event handler receives an argument of type SoundRecognizerDoneEventArgs having the following parameters:

 

Parameter

Description

 

 

nSessionUniqueId

Number representing the unique identifier of the recognition session

nResult

The result of the sound recognition session.

Value

Meaning

 

 

Negative value

An error occurred, check the LastError property value in order to see the error code meaning

enumErrorCodes.ERR_NOERROR (0)

The sound recognition was successful and the nSessionUniqueId parameter can be 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.