3
$\begingroup$

I have a bunch of videos recorded from a Samsung Galaxy S6. They all have a resolution of 3840x2160 and are supposed to be at 30fps. The weird thing is, some of the clips have video segments twice the length of the audio. In Blender my project's framerate is set to 30fps.

Looking at the source files in VLC, all the video framerates are about 30fps. Why is it that some of the files imported have video segments twice the length they should? For example, the video segment will be 400 frames, and the audio will be 200. I can set Blender's expected frame-rate to 60, which causes the a/v to line up. But then the video plays back poorly (since it was not 60fps to begin with, something is messed up).

Note the following information reported by VLC.

Codec: H264 - MPEG-4 AVC (part 10) (avc1)
Resolution: 3840x2178
Display resolution: 3840x2160
Frame rate: 29.981651
Decoded format: Planar 4:2:0 YUV
$\endgroup$
5
  • $\begingroup$ related: blender.stackexchange.com/a/6270/1853 and blender.stackexchange.com/questions/10855/… and blender.stackexchange.com/a/31895/1853 $\endgroup$
    – user1853
    Aug 17, 2015 at 2:24
  • 1
    $\begingroup$ You could report this as a bug, or at least make available a file which fails to import properly. $\endgroup$
    – ideasman42
    Sep 7, 2015 at 6:46
  • 2
    $\begingroup$ After looking at the other stackexchange queries noted above, I am not persuaded that they relate to the same issue. $\endgroup$
    – 3pointedit
    Sep 8, 2015 at 12:56
  • $\begingroup$ Yes, the suggested duplicate has a similar question, but the answer does not answer the question. This has to be a bug with blender, so I will do as suggested and report it with a sample faulty video to import. I will post the bug ID here later. $\endgroup$ Sep 8, 2015 at 13:19
  • $\begingroup$ Here's a workaround for you: blender.stackexchange.com/a/49219/2843 $\endgroup$
    – Samoth
    Mar 21, 2016 at 19:46

1 Answer 1

4
$\begingroup$

Modern codecs like AVCHD often are not well supported by Blender's decoder. You may find that these clips are frame segmented, which Blender incorrectly treats as sort of interlaced, thereby reducing the frame number but maintaining frame rate. Only solution is to transcode into a format that Blender does understand. Check out this thread for details on the effect of frame segmented media in Blender. Sorry.

$\endgroup$
5
  • 2
    $\begingroup$ I thought blender used (up-to-date) versions of ffmpeg for encoding/decoding? $\endgroup$
    – gandalf3
    Aug 17, 2015 at 7:16
  • $\begingroup$ Ok, yeah that's probably the issue here. Maybe I'll have to build Blender from source and swap in a newer ffmpeg. $\endgroup$ Aug 17, 2015 at 14:14
  • $\begingroup$ Given Blender's frame handling it may be that it cannot recognize the temporal nature of the codec you want to use. $\endgroup$
    – 3pointedit
    Aug 18, 2015 at 1:27
  • $\begingroup$ While blender may be compiled using the newest ffmpeg version, it hasn't been programmed to use all available features and formats. $\endgroup$
    – sambler
    Aug 20, 2015 at 16:43
  • 2
    $\begingroup$ This answer is incorrect, as mentioned, Blenders decoder is not old (You can see the ffmpeg version used by going to Help -> System Info) $\endgroup$
    – ideasman42
    Sep 7, 2015 at 6:44

Not the answer you're looking for? Browse other questions tagged or ask your own question.