Answers.Body: <p>You can tell which one gets out of synch like this:</p>
  
  <p>Set up your camera and your phone like you usually do. Put a clock that shows seconds right in front of the camera. Then, even though this sounds boring, record yourself counting off the seconds.</p>
  
  <p>Synchronize the video and audio in Premiere Pro like you usually do. When they get out of synch, check whether the video lost a second, or whether the audio lost a second. You should be able to tell based on the repetitive rhythm.</p>
  
  <p>Then, as @AJHenderson pointed out, you should replace the piece of equipment that failed. I agree that a camera that can accept external audio input is probably the best option, though it's expensive.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-06-03T02:21:06.003Z
Answers.Text: I have another theory, since the phone I am using was thethering to my tablet is constantly uploading images to flickr at the time, delayed the audio recording for a bit.
Answers.UserDisplayName: Mr A
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-06-03T02:23:00.730Z
Answers.Text: Curious question: TV and Film producers usually record their audio separate from its source, and they are sync in the post. They are not directly plugging their mic at the camera, do they?
Answers.UserDisplayName: Mr A
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-06-03T16:59:38.743Z
Answers.Text: @MrA - AJ Henderson would probably answer this better, but if I recall from film school the answer is no - they're recorded on separate devices and synched in post production. I believe the advantage with a video camera is that when you plug in a mic, it synchs the audio with the video for you, and you also get the advantage of a good quality microphone placed near the sound source. (If these answers are helping, please give them an up-vote! Thanks.)
Answers.UserDisplayName: BrettFromLA
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-06-03T21:39:07.560Z
Answers.Text: re: sep sound. This was the rule when shooting film, but is less common when shooting video. Modern video recorders have excellent sound tracks, easily as good as a Nagra. Even when sep sound is used, if the video recording medium can take sound, it's smart to feed it the same or compatible source to help later syncing, and for backup. And pros using sep sound will often use a common timecode recorded to all devices (or will sync device TCs between shots). But in any case, 'plugging a mic into the camera' is not pro practice -- there's always a mixer.
Answers.UserDisplayName: Jim Mack
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-06-02T18:07:07.610Z
Answers.LastActivityDate: 2014-06-02T18:07:07.610Z
Answers.UserDisplayName: BrettFromLA
Answers.Body: <p>There are any number of possibilities, but the most likely ones all involve getting better equipment.  The most severe sync problems with phones tend to come from phones that use variable framerate video or tend to have cheap encoders that tend to drop or delay frames.</p>
  
  <p>When you are recording video, each frame has to be recorded more or less in real time.  There is a slight buffer available to store frames while they are processed, but if images are not processed at the rate they are shot, then eventually that buffer fills.  If a phone can't keep up, it has two options, either drop a frame outright and skip to the next one or use a file format that lets it alter the frame rate on the fly and record fewer frames per second when it has trouble.</p>
  
  <p>Both of these approaches often destroy any kind of audio sync.  The variable frame rate, if well implemented, should limit drift a bit more since the frames should still advance at a fairly consistent rate of time, but they may get delayed and become out of sync.  Dropped frames are generally far worse.  Since nothing exists for that frame, the next frame is simply used and a slice of time is lost in the video that isn't lost in a separate audio stream that didn't have the dropped frame.</p>
  
  <p>Both of these problems are unfortunately hardware dependent and there is no way to fix them on the hardware you have.  (You could try to reduce resolution to make the job easier for the encoder I suppose.)  If one of these is the source of the issue, getting another camera with a better encoder is the only other option you really have available if you want to maintain the resolution you are using.</p>
  
  <p>Another possible problem that is less common today, is that the internal timecode clock may simply be fast or slow.  For the most part frame timing is pretty consistent with modern technology, but if there is a problem, you can try syncing at the beginning and end of the video and adjust the audio speed accordingly.  Check a few times throughout the middle when you do this, because most modern problems will probably not be this simple and the middle will still be out of sync.</p>
  
  <p>An even better solution is to use a camera that can accept an external audio input.  By syncing the audio to the video in real time while recording on the same device, you can ensure proper timing is maintained by the encoder.  It's still probably a good idea to do an external recording as well, since this will help detect if there were capture problems, but using an external audio input is far simpler than dealing with sync issues after the fact.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-06-03T02:24:13.000Z
Answers.Text: Thanks! But I am using my smartphone as a audio recording device and a point-and-shoot to record the video.
Answers.UserDisplayName: Mr A
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-06-03T02:34:47.820Z
Answers.Text: Ah, I misunderstood, but the answer is still relevant for the point and shoot situation too.  It does make it more likely towards the cheap encoder lagging and failing to keep good time code.  Audio recording is generally far easier and phones tend to have good clocks because they have to keep good time to communicate wirelessly well.  Point and shoots on the other hand usually add video as an afterthought and can often do marginal jobs at holding consistent timing (since it isn't needed for most consumer stuff.)
Answers.UserDisplayName: AJ Henderson
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-06-03T04:21:17.243Z
Answers.Text: Interesting thought. You are suspecting the point-and-shoot as the cause of the syncing issue. I will keep that in mind and do the test from the other users and see.
Answers.UserDisplayName: Mr A
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-06-02T14:04:01.823Z
Answers.LastActivityDate: 2014-06-02T14:04:01.823Z
Answers.UserDisplayName: AJ Henderson
Answers.Body: <p>A/V sync problems are noticeable at about +/- 0.1 sec.  The samplerate clock in your phone and camera would have to be exactly the same speed to within 0.1 sec over 10 mins, or however long your clips are, for you to be able align at only one point.</p>
  
  <p><code>0.1 / (10 * 60) = .0001</code>.  That's about 1 part in 10k.  <a href="https://en.wikipedia.org/wiki/Quartz_clock" rel="nofollow noreferrer">Wikipedia</a> says quartz clocks are often as good as 6 parts per million stability.  The stuff I skimmed in that and <a href="https://en.wikipedia.org/wiki/Crystal_oscillator#Stability_and_aging" rel="nofollow noreferrer">this</a> indicate that it probably costs a bit extra to get the clock frequency that close out of the factory.  (and the 6ppm is the kind of long-term drift you can expect around the starting point, not the absolute accuracy of typical gear.)</p>
  
  <p>Keep in mind, most cameras, esp. ones primarily made for still-image photography, don't need a clock as accurate as a wristwatch, so they probably don't have one.  Because that would cost extra.</p>
  
  <p>I saw exactly this kind of drift between the audio from my Panasonic Lumix and audio recorded at the same time on a Dell laptop.  See <a href="https://video.stackexchange.com/questions/14529/sync-separate-audio-to-videobad-camera-audio-free-nle-recommendations/14549">Sync separate audio to video+bad-camera-audio, free NLE recommendations</a>, where I describe a slow way to manually sync clips, and ask for a quicker automated way.</p>
  
  <p>Anyway, this lack of clock sync didn't surprise me at all.  It's nothing to do with frame dropping, or bad quality gear.  It should work fine to assume that both clocks involved each run at a constant speed, just not at the SAME speed.  So you can correct a clip with a linear 2-parameter correction: offset + stretch.</p>
  
  <p>I agree with AJ Henderson's suggestion that it's probably the camera's clock that's less likely to be right.  Phones have GPS receivers for timekeeping, and may or may not use that accurate timesource as the clock for their audio input samplerate.  And also as AJ points out, need to do wifi, which probably requires calibrated clock sources, unless they can just lock on to a received frequency.  Not sure how big a deal accurate clocks are with modern wifi modulations, but probably a big deal.</p>
  
  <p>I would have expected issues recording on any two devices that don't derive their sample clock from the same timesource.  Until portable GPS receivers were available, <a href="https://en.wikipedia.org/wiki/SMPTE_timecode#Studio_operations_and_master_clocks" rel="nofollow noreferrer">movie studios</a> had a master clock that distributed time to all A/V recording devices, so 1 real hour of footage from one camera would have exactly as many frames as 1 real hour of footage from another camera.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-01-26T02:39:57.770Z
Answers.LastActivityDate: 2015-01-26T02:39:57.770Z
Answers.LastEditDate: 2017-04-13T12:46:08.110Z
Answers.UserDisplayName: Peter Cordes
Body: <p>I have recorded interviews using a point and shoot camera for the video and my android phone with Smart Recorder. The camera records in MOV and is uncompress with mono audio. Then I use my smartphone to record myself and the interviewee, since the camera is far away to hear us. The audio is in .wav and I use Premiere Pro to align them. While it does work at the start, sometimes it magically gets out of sync all of the sudden, so I have to cut the audio so that I can catch up. </p>
  
  <p>I am puzzled, and would like to have your insights on how to keep this at a minimum if possible, eliminate it. My theory is that sampling rate is an issue. If this is incorrect, please advice otherwise.</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2014-06-02T11:49:29.270Z
Comments.Text: If it really does jump out of sync then it's not likely to be a rate issue, which would cause it to drift. But often, things may seem to jump out of sync simply because it suddenly becomes noticeable. As an experiment, get a clapper or similar and shoot it once every few seconds for the length of an ordinary interview. Does it truly jump out, or does it drift? That will help determine a solution.
Comments.UserDisplayName: Jim Mack
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2014-06-03T02:23:39.473Z
Comments.Text: @JimMack Thanks for the wonderful advice. I'll do that later.
Comments.UserDisplayName: Mr A
Tags: <video><video-editor><audio><sync>
Title: Does the Sampling Rate affect the syncing process to a video source?
UserDisplayName: Mr A
ThreadText: # Does the Sampling Rate affect the syncing process to a video source?
  
  (Asked by: username_0 on 2014-06-02)
  
  I have recorded interviews using a point and shoot camera for the video and my android phone with Smart Recorder. The camera records in MOV and is uncompress with mono audio. Then I use my smartphone to record myself and the interviewee, since the camera is far away to hear us. The audio is in .wav and I use Premiere Pro to align them. While it does work at the start, sometimes it magically gets out of sync all of the sudden, so I have to cut the audio so that I can catch up.
  
  I am puzzled, and would like to have your insights on how to keep this at a minimum if possible, eliminate it. My theory is that sampling rate is an issue. If this is incorrect, please advice otherwise.
  
  **Tags:** video, video-editor, audio, sync
  
  > **Comments:**
  > **username_1**: If it really does jump out of sync then it's not likely to be a rate issue, which would cause it to drift. But often, things may seem to jump out of sync simply because it suddenly becomes noticeable. As an experiment, get a clapper or similar and shoot it once every few seconds for the length of an ordinary interview. Does it truly jump out, or does it drift? That will help determine a solution.  
  > **username_0**: @username_1 Thanks for the wonderful advice. I'll do that later.  
  
  ---
  
  ## 3 answers
  
  ### Answer by username_2 on 2014-06-02. Score: 2
  
  You can tell which one gets out of synch like this:
  
  Set up your camera and your phone like you usually do. Put a clock that shows seconds right in front of the camera. Then, even though this sounds boring, record yourself counting off the seconds.
  
  Synchronize the video and audio in Premiere Pro like you usually do. When they get out of synch, check whether the video lost a second, or whether the audio lost a second. You should be able to tell based on the repetitive rhythm.
  
  Then, as @username_3 pointed out, you should replace the piece of equipment that failed. I agree that a camera that can accept external audio input is probably the best option, though it's expensive.
  
  > **Comments:**
  > **username_0**: I have another theory, since the phone I am using was thethering to my tablet is constantly uploading images to flickr at the time, delayed the audio recording for a bit.  
  > **username_0**: Curious question: TV and Film producers usually record their audio separate from its source, and they are sync in the post. They are not directly plugging their mic at the camera, do they?  
  > **username_2**: @MrA - AJ username_3 would probably answer this better, but if I recall from film school the answer is no - they're recorded on separate devices and synched in post production. I believe the advantage with a video camera is that when you plug in a mic, it synchs the audio with the video for you, and you also get the advantage of a good quality microphone placed near the sound source. (If these answers are helping, please give them an up-vote! Thanks.)  
  > **username_1**: re: sep sound. This was the rule when shooting film, but is less common when shooting video. Modern video recorders have excellent sound tracks, easily as good as a Nagra. Even when sep sound is used, if the video recording medium can take sound, it's smart to feed it the same or compatible source to help later syncing, and for backup. And pros using sep sound will often use a common timecode recorded to all devices (or will sync device TCs between shots). But in any case, 'plugging a mic into the camera' is not pro practice -- there's always a mixer.  
  
  ---
  
  ### Answer by username_3 on 2014-06-02. Score: 1
  
  There are any number of possibilities, but the most likely ones all involve getting better equipment. The most severe sync problems with phones tend to come from phones that use variable framerate video or tend to have cheap encoders that tend to drop or delay frames.
  
  When you are recording video, each frame has to be recorded more or less in real time. There is a slight buffer available to store frames while they are processed, but if images are not processed at the rate they are shot, then eventually that buffer fills. If a phone can't keep up, it has two options, either drop a frame outright and skip to the next one or use a file format that lets it alter the frame rate on the fly and record fewer frames per second when it has trouble.
  
  Both of these approaches often destroy any kind of audio sync. The variable frame rate, if well implemented, should limit drift a bit more since the frames should still advance at a fairly consistent rate of time, but they may get delayed and become out of sync. Dropped frames are generally far worse. Since nothing exists for that frame, the next frame is simply used and a slice of time is lost in the video that isn't lost in a separate audio stream that didn't have the dropped frame.
  
  Both of these problems are unfortunately hardware dependent and there is no way to fix them on the hardware you have. (You could try to reduce resolution to make the job easier for the encoder I suppose.) If one of these is the source of the issue, getting another camera with a better encoder is the only other option you really have available if you want to maintain the resolution you are using.
  
  Another possible problem that is less common today, is that the internal timecode clock may simply be fast or slow. For the most part frame timing is pretty consistent with modern technology, but if there is a problem, you can try syncing at the beginning and end of the video and adjust the audio speed accordingly. Check a few times throughout the middle when you do this, because most modern problems will probably not be this simple and the middle will still be out of sync.
  
  An even better solution is to use a camera that can accept an external audio input. By syncing the audio to the video in real time while recording on the same device, you can ensure proper timing is maintained by the encoder. It's still probably a good idea to do an external recording as well, since this will help detect if there were capture problems, but using an external audio input is far simpler than dealing with sync issues after the fact.
  
  > **Comments:**
  > **username_0**: Thanks! But I am using my smartphone as a audio recording device and a point-and-shoot to record the video.  
  > **username_3**: Ah, I misunderstood, but the answer is still relevant for the point and shoot situation too.  It does make it more likely towards the cheap encoder lagging and failing to keep good time code.  Audio recording is generally far easier and phones tend to have good clocks because they have to keep good time to communicate wirelessly well.  Point and shoots on the other hand usually add video as an afterthought and can often do marginal jobs at holding consistent timing (since it isn't needed for most consumer stuff.)  
  > **username_0**: Interesting thought. You are suspecting the point-and-shoot as the cause of the syncing issue. I will keep that in mind and do the test from the other users and see.  
  
  ---
  
  ### Answer by username_4 on 2015-01-26. Score: 0
  
  A/V sync problems are noticeable at about +/- 0.1 sec. The samplerate clock in your phone and camera would have to be exactly the same speed to within 0.1 sec over 10 mins, or however long your clips are, for you to be able align at only one point.
  
  `0.1 / (10 * 60) = .0001`. That's about 1 part in 10k. [Wikipedia](https://en.wikipedia.org/wiki/Quartz_clock) says quartz clocks are often as good as 6 parts per million stability. The stuff I skimmed in that and [this](https://en.wikipedia.org/wiki/Crystal_oscillator#Stability_and_aging) indicate that it probably costs a bit extra to get the clock frequency that close out of the factory. (and the 6ppm is the kind of long-term drift you can expect around the starting point, not the absolute accuracy of typical gear.)
  
  Keep in mind, most cameras, esp. ones primarily made for still-image photography, don't need a clock as accurate as a wristwatch, so they probably don't have one. Because that would cost extra.
  
  I saw exactly this kind of drift between the audio from my Panasonic Lumix and audio recorded at the same time on a Dell laptop. See [Sync separate audio to video+bad-camera-audio, free NLE recommendations](https://video.stackexchange.com/questions/14529/sync-separate-audio-to-videobad-camera-audio-free-nle-recommendations/14549), where I describe a slow way to manually sync clips, and ask for a quicker automated way.
  
  Anyway, this lack of clock sync didn't surprise me at all. It's nothing to do with frame dropping, or bad quality gear. It should work fine to assume that both clocks involved each run at a constant speed, just not at the SAME speed. So you can correct a clip with a linear 2-parameter correction: offset + stretch.
  
  I agree with AJ username_3's suggestion that it's probably the camera's clock that's less likely to be right. Phones have GPS receivers for timekeeping, and may or may not use that accurate timesource as the clock for their audio input samplerate. And also as AJ points out, need to do wifi, which probably requires calibrated clock sources, unless they can just lock on to a received frequency. Not sure how big a deal accurate clocks are with modern wifi modulations, but probably a big deal.
  
  I would have expected issues recording on any two devices that don't derive their sample clock from the same timesource. Until portable GPS receivers were available, [movie studios](https://en.wikipedia.org/wiki/SMPTE_timecode#Studio_operations_and_master_clocks) had a master clock that distributed time to all A/V recording devices, so 1 real hour of footage from one camera would have exactly as many frames as 1 real hour of footage from another camera.
  
  
  ---
  
  