Skip to content
This repository has been archived by the owner on Apr 2, 2023. It is now read-only.

Switch implementation to minimp3 #21

Open
hajimehoshi opened this issue Jan 24, 2018 · 5 comments
Open

Switch implementation to minimp3 #21

hajimehoshi opened this issue Jan 24, 2018 · 5 comments

Comments

@hajimehoshi
Copy link
Owner

https://github.com/lieff/minimp3

It looks like minimp3 is cleaner, faster and well tested. It is only about 1700 lines and switching to it is not so hard.

@wsc1
Copy link

wsc1 commented Sep 11, 2018

would switching mean use cgo?

@hajimehoshi
Copy link
Owner Author

I'd like to avoid using cgo, then no. Porting this to Go might be an option, but not decided yet.

@pior
Copy link

pior commented Dec 15, 2019

I just tested both implementation for a project running on RaspberryPi zero, on this platform the CPU usage is an important aspect:

  • minimp3 -> ~35% of CPU
  • go-mp3 -> ~75% of CPU

Source mp3: 256kbps 44khz stereo

@nadoo
Copy link

nadoo commented Jun 12, 2020

I just tested both implementation for a project running on RaspberryPi zero, on this platform the CPU usage is an important aspect:

  • minimp3 -> ~35% of CPU
  • go-mp3 -> ~75% of CPU

Source mp3: 256kbps 44khz stereo

What about the speed? Read a mp3 file and save them to a pcm file.

@joonas-fi
Copy link

joonas-fi commented Feb 24, 2021

What about the speed? Read a mp3 file and save them to a pcm file.

An implementation using less CPU on a streaming load should always be faster in the task overall when scaling to "full throttle", i.e. to 100 % CPU.

Same variables, different perspective (speed and CPU usage are inherently related).

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

No branches or pull requests

5 participants