I am having trouble importing an mp4 into blender.

The mp4 was created using Android Debug Bridge screen record feature.

When I drag the video in, the first and most obvious problem, is that it says it is 300000 frames in length. The video is only 1 minute long though, so that doesn't make any sense.

When I play the video in blender, the frames do no move. Unless I zoom out massively, and skip greatly along the video and find a certain point where the actual video is.

So it is almost like the 1 min video is imported in a padded with like 200min worth of copies. of the first frame in front and behind of the video.

Edit: Apparently from this output of ffmpeg, the aource video is variable framerate. I wonder if blender does not support variable framerate video?

ffmpeg -i android_record1.mp4 -crf 0 ../corrected/output.mp4
ffmpeg version N-78598-g98a0053 Copyright (c) 2000-2016 the FFmpeg developers
  built with gcc 5.3.0 (GCC)
  configuration: --enable-gpl --enable-version3 --disable-w32threads --enable-avisynth --enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libdcadec --enable-libfreetype --enable-libgme --enable-libgsm --enable-libilbc --enable-libmodplug --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-librtmp --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-libzimg --enable-lzma --enable-decklink --enable-zlib
  libavutil      55. 18.100 / 55. 18.100
  libavcodec     57. 24.103 / 57. 24.103
  libavformat    57. 25.101 / 57. 25.101
  libavdevice    57.  0.101 / 57.  0.101
  libavfilter     6. 34.100 /  6. 34.100
  libswscale      4.  0.100 /  4.  0.100
  libswresample   2.  0.101 /  2.  0.101
  libpostproc    54.  0.100 / 54.  0.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'android_record1.mp4':
    major_brand     : mp42
    minor_version   : 0
    compatible_brands: isommp42
    creation_time   : 2016-02-24 20:17:38
  Duration: 00:00:33.54, start: 0.000000, bitrate: 921 kb/s
    Stream #0:0(eng): Video: h264 (Baseline) (avc1 / 0x31637661), yuv420p, 1280x800, 918 kb/s, SAR 1:1 DAR 8:5, 12.94 fps, 90k tbr, 90k tbn, 180k tbc (default)
      creation_time   : 2016-02-24 20:17:38
      handler_name    : VideoHandle
[libx264 @ 00000000039fea40] using SAR=1/1
[libx264 @ 00000000039fea40] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 AVX2 LZCNT BMI2
[libx264 @ 00000000039fea40] profile High 4:4:4 Predictive, level 3.2, 4:2:0 8-bit
[libx264 @ 00000000039fea40] 264 - core 148 r2665 a01e339 - H.264/MPEG-4 AVC codec - Copyleft 2003-2016 - http://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x1:0x111 me=hex subme=7 psy=0 mixed_ref=1 me_range=16 chroma_me=1 trellis=0 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=0 chroma_qp_offset=0 threads=6 lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=0 weightp=2 keyint=250 keyint_min=12 scenecut=40 intra_refresh=0 rc=cqp mbtree=0 qp=0
Output #0, mp4, to '../corrected/output.mp4':
    major_brand     : mp42
    minor_version   : 0
    compatible_brands: isommp42
    encoder         : Lavf57.25.101
    Stream #0:0(eng): Video: h264 (libx264) ([33][0][0][0] / 0x0021), yuv420p, 1280x800 [SAR 1:1 DAR 8:5], q=-1--1, 12.94 fps, 315k tbn, 12.94 tbc (default)
      creation_time   : 2016-02-24 20:17:38
      handler_name    : VideoHandle
      encoder         : Lavc57.24.103 libx264
    Side data:
      cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
Stream mapping:
  Stream #0:0 -> #0:0 (h264 (native) -> h264 (libx264))
Press [q] to stop, [?] for help
Past duration 0.725090 too large
Past duration 0.716301 too large
Past duration 0.818840 too large
Past duration 0.936516 too large   2196kB time=00:00:05.71 bitrate=3145.4kbits/s dup=66 drop=0 speed=9.91x
Past duration 0.644524 too large
Past duration 0.733879 too large
Past duration 0.888176 too large
Past duration 2.010735 too large
Past duration 0.915520 too large
Past duration 0.774406 too large   3675kB time=00:00:14.37 bitrate=2094.3kbits/s dup=149 drop=8 speed=  13x
Past duration 2.095695 too large
Past duration 1.697746 too large
Past duration 0.891594 too large
Past duration 2.141594 too large   4102kB time=00:00:22.02 bitrate=1525.6kbits/s dup=224 drop=18 speed=13.7x
frame=  436 fps=180 q=-1.0 Lsize=    4702kB time=00:00:33.69 bitrate=1143.2kbits/s dup=227 drop=225 speed=13.9x
video:4699kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.054633%
[libx264 @ 00000000039fea40] frame I:2     Avg QP: 0.00  size:316054
[libx264 @ 00000000039fea40] frame P:434   Avg QP: 0.00  size:  9630
[libx264 @ 00000000039fea40] mb I  I16..4..PCM: 53.7%  0.0% 46.3%  0.0%
[libx264 @ 00000000039fea40] mb P  I16..4..PCM:  1.3%  0.0%  0.4%  0.0%  P16..4:  3.5%  0.2%  0.1%  0.0%  0.0%    skip:94.6%
[libx264 @ 00000000039fea40] 8x8 transform intra:0.0% inter:25.9%
[libx264 @ 00000000039fea40] coded y,uvDC,uvAC intra: 52.8% 52.4% 51.4% inter: 2.1% 2.9% 2.9%
[libx264 @ 00000000039fea40] i16 v,h,dc,p: 50% 50%  0%  0%
[libx264 @ 00000000039fea40] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 31% 49%  6%  3%  3%  2%  2%  2%  3%
[libx264 @ 00000000039fea40] i8c dc,h,v,p: 21% 47% 32%  0%
[libx264 @ 00000000039fea40] Weighted P-Frames: Y:0.0% UV:0.0%
[libx264 @ 00000000039fea40] ref P L0: 90.2%  1.2%  6.2%  2.4%
[libx264 @ 00000000039fea40] kb/s:1142.43

I've experienced the same issue today and spent ages trying to convert a large mp4 to mkv and it still had issues.

I managed to find a fix which worked inside Blender, and that was importing the mp4 and then clicking Add -> Effect -> Speed Control.

add effect speed control

Making sure the multiply speed was set to 1, I then dragged the sound and video to the original length of video and everything matched up fine.

| improve this answer | |

enter image description here

The attached Image shows the following:

On the Properties area, under the Dimensions Fly-out section, there is both a Frame Rate field, and a Time Remapping field.

Use these to both remap the percentage ratio, and attempt to match the orignal frame rate.

This may or may not be the answer, it is worth a shot to try and solve the problem without having to go outside of Blender.

| improve this answer | |

Have you tried converting the MP4 to an AVI or another format? I've never actually tried importing an mp4 but this is the first thing I'd try if it happened to me.

If you don't have software to do it perhaps you could use an online one clip converter

| improve this answer | |

I solved this issue by opening the MP4 in windows movie maker and then saving a new version.

I guess for whatever reason Blender does not like the subformat of mp4 that android spits out on screen record.

| improve this answer | |
  • $\begingroup$ It sounds like a time mapping thing to me. If you look at the Windows properties of the video, how many frames does it have? Then do the time mapping in Blender (I would be very curious to see if this would straiten out). Glad you found a sufficient solution though. $\endgroup$ – Rick Riggs Feb 19 '16 at 22:16
  • $\begingroup$ How do I do the time mapping? $\endgroup$ – ScottF Feb 19 '16 at 23:22
  • $\begingroup$ I'm adding this as an answer, to respond to this, as the comments don't allow for images. $\endgroup$ – Rick Riggs Feb 20 '16 at 1:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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