GZIP/compression for mp3's?

1,753 views
Skip to first unread message

koolaid

unread,
Aug 30, 2011, 3:50:38 PM8/30/11
to jPlayer: HTML5 Audio & Video for jQuery
So I am almost done developing my mobile site which includes jplayer.
I want my website to be as fast a s possible on mobile phones so I was
going to compress all my css, javascript, and php files with tools
such as the YUI compressor. I was also going to enable GZip if the
browser supports it.


The only thing that wont be compressed is the Audio. I am assuming
that this is not possible?


Currently jPlayer does a great job with loading my mp3s. I have all
my mp3's encoded at 32kbps. The length of my files can range from
45-90mins in length and are about 7-15MB in size. But if there is a
way to further optimize the amount of data being transferred(with out
going less than 32kbps) let me know.

Carl Forde

unread,
Aug 31, 2011, 11:55:17 AM8/31/11
to jPlayer: HTML5 Audio & Video for jQuery
On Aug 30, 12:50 pm, koolaid <koolaid1...@gmail.com> wrote:

> The only thing that wont be compressed is the Audio.  I am assuming
> that this is not possible?

Since you're using mp3s the audio is already compressed. Running it
through zip, and friends, will consume cycles for very little benefit.
You /might/ get a 2 or 3 percent reduction. On the other hand, the
file sizes could increase instead.

Carl

ps. good introduction to mp3s here:
http://arstechnica.com/old/content/2007/10/the-audiofile-understanding-mp3-compression.ars

Otávio C A Serra

unread,
Aug 31, 2011, 12:08:45 PM8/31/11
to jpl...@googlegroups.com
Hy,

Anybody know or imagine one way how can we stop jPlayer sound / video
when user push button play or interact with youtube or other kinds of
embeebed flash players? And it is possible restart jPlayer after user
focusing others objects or other actions? Anyone can help us with one
example?

Thanks

Otavio

Mark Panaghiston

unread,
Aug 31, 2011, 6:14:27 PM8/31/11
to jpl...@googlegroups.com
Do not GZip the MP3.

From the docs:
http://jplayer.org/latest/developer-guide/#jPlayer-server-response
Do Not GZIP the Media

Disable GZIP encoding of all the media files. Media files are already compressed and the GZIP will just waste CPU on your server.

The Adobe Flash Plugin will experience issues if you GZIP the media.

Do not GZIP the Jplayer.swf file either. Feel free to GZIP the JavaScript.


Reply all
Reply to author
Forward
0 new messages