Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash on FingerprintCommandBuilder.Instance with FFmpegAudioService #230

Open
jscoys opened this issue Nov 29, 2024 · 2 comments
Open

Crash on FingerprintCommandBuilder.Instance with FFmpegAudioService #230

jscoys opened this issue Nov 29, 2024 · 2 comments

Comments

@jscoys
Copy link

jscoys commented Nov 29, 2024

Describe the bug
Firstly first, wonderful software, thanks for that!
I was using SoundFingerprintingAudioService and wanted to switch to FFmpegAudioService. Unfortunately, I'm having trouble making it working properly with FFmpeg.

To Reproduce
It crashes when I'm trying to

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
Here are the characteristics of the wave file I want to store in memory:
image

Here is the error I'm getting ("System.AggregateException: 'One or more errors occurred. (Specified method is not supported.)'" - "NotSupportedException: Specified method is not supported.")
image

Desktop (please complete the following information):

  • Windows 11
  • Visual studio
  • All nuget packages are there (Emy included)
  • FFMPEG is well placed in the required directory

Additional context
Here is the function where it's crashing with FFmpegAudioService (But working with SoundFingerprintingAudioService):
public string StoreFileInMemory(string filePath)
{
try
{
var track = new TrackInfo(filePath, filePath, "Unknown Artist");

    var hashes = FingerprintCommandBuilder.Instance
        .BuildFingerprintCommand()
        .From(filePath)
        .UsingServices(audioService)
        .Hash()
        .Result;

    // Insert the track and fingerprints into the model service
    modelService.Insert(track, hashes);

    // Return the track ID (unique for each track)
    return track.Id;
}

catch (AggregateException aggEx)
{
    foreach (var inner in aggEx.InnerExceptions)
    {
        Debug.WriteLine($"Inner Exception: {inner.Message}");
        Debug.WriteLine(inner.StackTrace);
    }
    throw;
}
catch (Exception ex)
{
    Debug.WriteLine($"Unexpected Error: {ex.Message}");
    Debug.WriteLine(ex.StackTrace);
    throw;
}

}

Thanks in advance for your help!

@AddictedCS
Copy link
Owner

It seems there is a version mismatch between the native DLLs and the ones referenced by NuGet.
Use the following version matrix: https://github.com/AddictedCS/soundfingerprinting/wiki/Audio-Services

@jscoys
Copy link
Author

jscoys commented Dec 5, 2024

Thanks for your help! Apparently I have the same versions for the two nuggets, should I do something?
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants