mp4parser

mp4 tag editing with java

限于喜欢 提交于 2021-01-27 15:56:18
问题 I want to edit tags of mp4 video file in java. I find out mp4parser on google code but there is no enough documentation for that. What would be the best lib for editing mp4 video tags in java. And is there any limitation for comment tag in mp4 video?? 回答1: So by tags you mean things like title, artist, album etc? In this case you can try the new API available in JCodec (org.jcodec.movtool.MetadataEditor). It also has a CLI (org.jcodec.movtool.MetadataEditorMain). Here's the basic usage: #

No audio in MP4 file - Android

↘锁芯ラ 提交于 2019-12-29 08:22:14
问题 I am using the MP4ParserMergeAudioVideo to add a new audio to an MP4 file. The library had said to use .wav file, if i keep a .wav file in the directory and give the name of the audiofile as example.m4a , I get a file not found exception. So I changed the file to a .m4a audio file. The code is given below. findViewById(R.id.append).setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { String root = Environment.getExternalStorageDirectory().toString(); Log.e("",""

mp4parser-Appending different mode videos

假如想象 提交于 2019-12-24 14:37:04
问题 I tried this library for appending videos-mp4parser ..it works fine for appending same mode videos..but i want to append different mode videos-time lapse and normal mode video..How should i proceed in tht?I tried below code for merging videos in Vid directory which works fine if all videos are in same mode but fails to append if videos are of different mode. public class MergedVideo extends AsyncTask<Void, Integer, String> { @Override protected void onPreExecute() { } ; @Override protected

mp4parser runs on device from Android Studio but crashes when manually installing the APK

一个人想着一个人 提交于 2019-12-23 07:28:19
问题 I'm using mp4parser to merge videos . The app runs perfect when running from A.S . but if I install the app manually (transfer and run the APK ) or if I run it from TestFairy , the app crashes. This started happening when I updated my Target Sdk to Lollipop . I've added the `aspectjrt-1.7.3.jar` `isoparser-1.0-RC-27.jar` into the libs dir in my project. I've also tried with below versions `aspectjrt-1.8.5.jar` `isoparser-1.0-RC-37.jar` `isoparser-1.0.6.jar`. Not sure if its the right way but

mp4parser runs on device from Android Studio but crashes when manually installing the APK

北城余情 提交于 2019-12-23 07:28:08
问题 I'm using mp4parser to merge videos . The app runs perfect when running from A.S . but if I install the app manually (transfer and run the APK ) or if I run it from TestFairy , the app crashes. This started happening when I updated my Target Sdk to Lollipop . I've added the `aspectjrt-1.7.3.jar` `isoparser-1.0-RC-27.jar` into the libs dir in my project. I've also tried with below versions `aspectjrt-1.8.5.jar` `isoparser-1.0-RC-37.jar` `isoparser-1.0.6.jar`. Not sure if its the right way but

It takes too long time to mux h264 into mp4 file using mp4parser

怎甘沉沦 提交于 2019-12-23 04:50:38
问题 I'm using mp4parser to mux h264 file and aac file into mp4 file.And the code is as belows. String h264Path = "path to my h264 file, generated by Android MediaCodec"; DataSource videoFile = new FileDataSourceImpl(h264Path); H264TrackImpl h264Track = new H264TrackImpl(videoFile, "eng", 5, 1); // 5fps. you can play with timescale and timetick to get non integer fps, 23.967 is 24000/1001 Movie movie = new Movie(); movie.addTrack(h264Track); Container out = new DefaultMp4Builder().build(movie);

Set metadata to mp4

感情迁移 提交于 2019-12-21 15:16:08
问题 I encode video with help of MediaCodec and MediaMuxer . As result I have mp4 video file. How can I set metadata (creating time) to this mp4 file? MediaMetadataRetriever can only read metadata, but not change. I don't want to use ffmpeg. I tried mp4parser library (this class), but it doesn't work for me. 回答1: Setting metadata in MP4 file is not a clear task because there is no generally supported specification, but most video players support Apple specs. More info here, here, and here. Here is

MP4Parser change video orientation

无人久伴 提交于 2019-12-18 06:49:49
问题 Im attempting to rotate a video that is in landscape into portrait using MP4Parser (or any other method if you know of one) currently playing with the TrackHeaderBox but unable to get the orientation to change at all, has anyone used this before that can spot the mistake I may of made? any help will go a long way thanks IsoFile out = new DefaultMp4Builder().build(result); // test double[] m = null; m = new double[] { 0.0, 1.0, 0.0, -1.0, 0.0, 0.0, 0.0, 0.0, 1.0 }; TrackBox tb = out

Rotate and append videos with mp4parser

放肆的年华 提交于 2019-12-14 01:48:37
问题 I would like to append several video files from the camera through mp4parser. Unfortunately, in the same fragment, despite the fact that I try to change the OrientationHint of the media recorder when changing camera, only the first one seems to work (ie. if I start with the front camera, the videos with the back camera are reversed and vice versa). To solve this problem, I tried to rotate the video that are in the wrong direction and that works (with the method of setMatrix mp4parser, the new

MP4Parser Can we have Android MediaPlayer directly act as a sink?

爱⌒轻易说出口 提交于 2019-12-13 01:06:32
问题 Lets say my I have my Mp4Parser Container java object and then instead of writing to a file and then supplying the URL of this file to the Android Media Player to play this video. Container outMux = new DefaultMp4Builder().build(countVideo); FileOutputStream fos = new FileOutputStream( new File("outputFinalVideo.mp4")); outMux.writeContainer(fos.getChannel()); fos.close(); In the above I am concatenating multiple videos and then Muxing with Audio and then I want this to be in memory and play