0

I looking for any SDK-LEVEL(without using ffmpeg) approach for compress video programmatically in android. I can't use ffmpeg cause its size overhead.Is there any lightweight solution for that ?

I want reduce size of video before uploaded to server (i can't modify server upload limit) so if you have any idea other than compressing video please share it.

note : my min-sdk version is 14

Mojtaba Asgari
  • 1,242
  • 1
  • 13
  • 24
  • 1
    What is the source of your video? If it comes from the device camera, then MediaRecorder will do it for you. – Alex Cohn Oct 13 '15 at 07:23
  • Not necessarily, user can attach video from SD too. but can you explain more about your idea ? – Mojtaba Asgari Oct 13 '15 at 07:39
  • 1
    The [MediaRecorder sample](http://developer.android.com/samples/MediaRecorder/index.html) shows how to compress the camera video stream. Note that you can use the [`MediaStore.ACTION_VIDEO_CAPTURE`](http://developer.android.com/intl/zh-tw/reference/android/provider/MediaStore.html#ACTION_VIDEO_CAPTURE) Intent, and the Camera app will compress the video for you. – Alex Cohn Oct 13 '15 at 07:49
  • If you want to reduce size of existing video, your question it possible duplicate of *[MediaMuxer video compression (change resolution)](http://stackoverflow.com/questions/29943121/mediamuxer-video-compression-change-resolution)*. – Alex Cohn Oct 13 '15 at 08:00
  • The further back you go, the harder your mission becomes. Older devices may have bad compatibility even if you succeed to forge some wrapper based on Stagefright. – Alex Cohn Oct 13 '15 at 08:17
  • that's true ,but a significant percentage of devices are on 14 and i can't ignore them. – Mojtaba Asgari Oct 13 '15 at 08:23

0 Answers0