Question

I'm trying to figure out how to resize/scale an mp4 video using mp4parser in an android app. After quite a bit of googling and looking through the mp4parser source and examples, I'm still not sure how to go about doing this.

Does mp4parser have some built in way of doing this?

If not, can I grab the raw video data and resize it myself using mp4parser? (a link to an example would be awesome if possible)

NOTES:

mp4parser website https://code.google.com/p/mp4parser/

I'm willing to consider using a different library than mp4parser, but I'd like something with licensing similar to LGPL. In other words, I am willing to supply library source code and give credit where credit is due, but I'd rather not be forced to make my source code publicly available. (This app will eventually be commercially available).

I need this functionality to append 2 files together that have different resolutions (taken from front camera and back camera).

I have successfully used mp4parser to append 2 files of the same resolutions.

I'm pretty new to video editing.

While I've relied on stackoverflow for many years, this is my very first question asked. Please be gentle. I'll gladly take constructive criticism on the proper way to ask questions here.

Was it helpful?

Solution

mp4parser will not have the ability to do this. To rescale a video, you must decode each frame, rescale then re-encode. ffmpeg (libavformat,libavcodec,swscale) can do this. As for LGPL compatibility, you may be able to achieve it for some codecs, but not all. I assume you are looking for LGPL to include this is a commercial app? If so, you must also license the codecs. For example, x264 is free/open source software. But distributing the videos it creates may require you to pay MPEG-LA.

OTHER TIPS

I am searching it for long time. I couldn't find samples or example. But i found working app in Google Play. click to see

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top