Skip to content

Commit

Permalink
New file generates 1 fingerprint less, probably because of silence at…
Browse files Browse the repository at this point in the history
… the beginning.
  • Loading branch information
AddictedCS committed Nov 29, 2016
1 parent 35765e1 commit 1ab852b
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,7 @@ public void CreateFingerprintsFromDefaultFileAndAssertNumberOfFingerprints()
.UsingServices(bassAudioService);

double seconds = tagService.GetTagInfo(PathToMp3).Duration;
int samples = (int)(seconds * fingerprintCommand.FingerprintConfiguration.SampleRate);
int expectedFingerprints = (samples / StaticStride) - 1;
int expectedFingerprints = (int)(seconds * fingerprintCommand.FingerprintConfiguration.SampleRate / StaticStride * StaticStride / StaticStride) - 2; // ? new file generates 1 fingerprint less;

var fingerprints = ((FingerprintCommand)fingerprintCommand).Fingerprint().Result;

Expand Down

0 comments on commit 1ab852b

Please sign in to comment.