Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4084564
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T18:27:21+00:00 2026-05-20T18:27:21+00:00

I using avfoundation to record video from my device and going to use imagepicker

  • 0

I using avfoundation to record video from my device and going to use imagepicker to select video from gallery and then upload it to local server.
Whenever i will fetch uploaded video from server it will not played by using mpmovieplayer, but if i stored some other video of .mov format it will played well. and sometimes my video also played well.
my question here is:
– is this because of framerate of video
– or is this because of streaming problem?

 ALAssetsLibrary *library = [[ALAssetsLibrary alloc] init];
if ([library videoAtPathIsCompatibleWithSavedPhotosAlbum:outputFileURL])
{
    [library writeVideoAtPathToSavedPhotosAlbum:outputFileURL
                                completionBlock:^(NSURL *assetURL, NSError *error)
    {
    if (error && [delegate respondsToSelector:@selector(assetLibraryError:forURL:)]) {
                                        [delegate assetLibraryError:error forURL:assetURL];

    }
    }];
} else {
    if ([delegate respondsToSelector:@selector(cannotWriteToAssetLibrary)])
    {
        [delegate cannotWriteToAssetLibrary];



    }
}

[[NSUserDefaults standardUserDefaults] setObject:outputFileURL forKey:@"StoreVideo"];

[library release]; 

if ([[UIDevice currentDevice] isMultitaskingSupported]) {
    [[UIApplication sharedApplication] endBackgroundTask:[self backgroundRecordingID]];
}

if ([delegate respondsToSelector:@selector(recordingFinished)]) {
    [delegate recordingFinished];
}

above is the code snipped i am using to save video in asset library after recording.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T18:27:22+00:00Added an answer on May 20, 2026 at 6:27 pm

    In order to stream video from a server and play it back with MPMoviePlayer, the file needs to be segmented with the mediafilesegmenter tool. I’m not sure if this is provided with Snow Leopard, but since these tools are updated frequently according to Apple, you should download their latest versions. See Technical Note TN2224 for more information on how to obtain these tools.

    The idea is to divide the file into small segments, say 10 seconds each, to facilitate streaming. The tool will create a playlist with an m3u8 extension. The URL to this file is what you will need to provide to MPMoviePlayer.

    Even though you are not doing live streaming, you still need to segment your video otherwise it MAY play back on some iOS devices under some iOS versions, but not guaranteed.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using the AVFoundation classes to capture the live video stream from the camera
Using PyObjC , you can use Python to write Cocoa applications for OS X.
iam using AVFoundation Framework to play mp3 file ,everything works great ، i have
I'm using AVAudioRecorder in the AVFoundation framework. I'm wondering how I can check for
How i do the following using the AudioToolbox framework instead of the AVFoundation playing
If i am palying a sound using the AVAudioPlayer in the AVFoundation framework (I
i am developing an application in which i am trying to record a video
Is there any way using AVFoundation and CoreVideo to get color info, aperture and
Is there a basic tutorial for the AVFoundation for use with the camera anywhere?
What's the best way to grab a succession of images from the camera using

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.