Issues while merging the videos using AVMutableComposition - objective-c

I have been working on merging of videos into a single video using the AVMutableComposition and have got the required output.But i'm getting two different types of issues while merging the videos.
1) I couldn't set the custom frames for the videos using the AVMutableVideoCompositionLayerInstruction.
2) While playing the merged video, the first merged video is been vanished(removed) after its been stopped. But the other videos are staying correctly after stopped in their respective location.
Please suggestion any solution..

1) if you want to change frame for merged video, you should set AVMutableVideoComposition render size
2) if you play first and the second video at the same time, the duration of the merged video will be the biggest duration from both videos, in that case you should handle the difference,place a kind of placeholder at the end of first video(can be last frame of the video)

Related

create js movieclip object containing an mp4 video in a tween does not work with gotoAndPlay calls

I have some code that used CreateJS /EaselJS to create a MovieClip that contains a Tween that contains an mp4 video. In MovieClip there is a method called 'gotoAndPlay' that you can use to change the timeline position of the playhead to a certain frame number. When using this method to change the play position of the video the tweens work but not the Tween that contains the mp4 movie...this object does not load is result in a blank video tag on the page except for the first play through of the clip. Once the mp4 video has been played it didn't play again if the position was set to it through gotoAndPlay...any ideas on how to fix this or if something wrong might be happening?
In ActionScript animations, FLV movies can be locked to the timeline. But in HTML Canvas animations, MP4 movies are not really fully-fledged "Animate" objects. They look the same for the most part but the integration is not as tight as in Flash.
Since the videos exist outside of the Canvas, you'll need to use jQuery or JavaScript to address them. This can be done by using the Code Snippets in the HTML5 Canvas - Components - Video folder.
As an advance warning, "seeking" to different locations in an MP4 video the way you described is not as reliable as it was in Flash. Browsers like Internet Explorer don't handle seeking well and will likely crash. If frame -by-frame accuracy is important, you may find the best visual results by avoiding the video component and converting your movie to an actual MovieClip in Animate CC, which will increase your file size significantly.

Video in video.js-Player not displayed correctly

I have a problem regarding a video that is not displayed correctly in the video.js player:
http://www.ulrichbangert.de/kakteen/zeitraffer_vjs.php?Idx=10
As you can see from the page source the dimensions of the player are set to 640x480. The video has the same dimensions which I verified by loading it into my local player and displaying the properties. But: At the left and the right of the video there is a gap of some pixels. The poster is displayed correctly without these gaps. This results in an ugly skip when the player switches from the video to the poster. The poster image is the last frame of the video.
Other videos like this one
http://www.ulrichbangert.de/orchid/zeitraffer.php?Idx=1
are playing fine without a skip but I can't find any difference between these and the faulty one.
My browser is Firefox 23.0.1 thus the ogv video is used.
Can anybody help?
Best regards - Ulrich

Is it possible play multiple clips using presentMoviePlayerViewControllerAnimated?

I have a situation where I'd like to play 2 video clips back to back using an MPMoviePlayerViewController displayed using presentMoviePlayerViewControllerAnimated.
The problem is that the modal view automatically closes itself as soon as the first movie is complete.
Has anyone found a way to do this?
Three options:
You may use MPMoviePlayerController and start the playback of the 2nd (Nth) item after the previous is complete. This however will introduce a small gap between the videos cause by identification and pre buffering of the content.
You may use AVQueuePlayer; AVQueuePlayer is a subclass of AVPlayer you use to play a number of items in sequence. See its reference for more.
You may use AVComposition for at runtime composing one video out of the two (or N) you need to play back. Note, this works only on locally stored videos and not on remote (streaming or progressive download). Then use AVPlayer for the playback.
It's not possible. If the video assets are in local file system, consider AVComposition.

Objective C : Video Compositions

I need a bit of advice. I currently have 4 videos, 20 seconds in length each, and one MP3, 5 minutes in length.
I am merging these lot into one video, cycling every 3 seconds to the next video, for the duration of the MP3 track.
Problem 1: The videos are 20 seconds each, the MP3 is 5 minutes. It means that I will run out of video. I resolved this by running each the videos in a loop using AVMutableComposition, then exporting each of them to their new respective files.
Next, I have a fifth video in which the 4 videos plays simultaneously, each in their own quadrant of the video. This video is also compose in an AVMutableComposition which is then exported the a separate video file.
Lastly, I take these 5 videos and MP3 track, and create a composition, using AVMutableComposition again, cycling through the different videos every 3 seconds. Then I export them to the final video.
Now, the issue I'm sitting with is that exporting all those videos takes up a lot of time. Is there a way for me to use the created AVMutableComposition objects to create the final video, instead of exporting the videos and then adding them to the final composition?
Regards,
EZFrag

IOS Segemnting a video

I want to segment a video into 9 sections jumble the sections about and then play them together. I am currently trying to use AVPlayer to do this. I can get the sections to load on the simulator but only the first 4 will load on the actual phone. I guess the resources are topping out.
My question is: Is AVPlayer the best framework to use for this (as it seems a waste to create a player item, player and playerlayer for each segment(Which I think is why the resources are topping out)) or is there a lower framework I can use to load one video and display certain segments of it on certain sreas of the screen?
Thanks