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

my webm videos are really big,why?(26 MB for a 10 second animation) #9

Closed
tariqazmat101 opened this issue Nov 30, 2019 · 5 comments
Closed

Comments

@tariqazmat101
Copy link

tariqazmat101 commented Nov 30, 2019

Hello, Does anyone else have the same problem as me?

Background info:
-The videos were rendered at 60fps,1920x1080, and at the lowest possible quality setting.
-I am using CCapture,a library for replaying canvas based animations. It uses this project for webm video rendering. (Perhaps CCapture is the culprit)

@thenickdude
Copy link
Owner

thenickdude commented Nov 30, 2019 via email

@thenickdude
Copy link
Owner

Ah yep it looks like CCapture uses 0.2.0, where the quality setting is non-functional. Try replacing that with https://github.com/thenickdude/webm-writer-js/releases/tag/v0.2.4

@tariqazmat101
Copy link
Author

tariqazmat101 commented Nov 30, 2019

thanks, I'll swap the versions soon and report back the results.

I render at 1080 p resolution.

for version webm-writer 0.2.0, playing around with the webm quality had a minor effect on file size. The file size shrunk by 7% when switching from highest to lowest quality setting.

@tariqazmat101
Copy link
Author

tariqazmat101 commented Nov 30, 2019

Swapping out to the newest version of webmwriter reduced file size from 26mb(highest quality) to 11mb(at 10 percent quality)!

It's a decent solution, but the video quality does degrade as you lower bit rate. I will have to find a fine balance between videoquality and size, haha.

Thanks!
EDIT: Oh, I understand why these WEBM files are so massive, it's because it's using intraframe compression, and not interframe.

from https://github.com/antimatter15/whammy,

"The cool thing about WebP which was exploited in Weppy is that it's actually based on the same codec as WebM, On2's VP8. That means the actual image data, when the container formats are ignored, are virtually interchangable. With a catch: it's intraframe only.

So it's a video encoder in that it generates .webm files which should play in just about any program or device which supports the WebM format. But interframe compression is actually a fairly important thing which could reduce the file size by an order of magnitude or more."

@thenickdude
Copy link
Owner

Thanks for the test, I'll submit a pull request to them to get it updated.

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