2

I have a video file (which includes a audio stream too). I want to determine its quality based on bit rate, bit depth, height, width, encoding etc. Among this what determines the quality of a video?

For example I have this mediainfo dump for a video

ID                                       : 1
Format                                   : AVC
Format/Info                              : Advanced Video Codec
Format profile                           : [email protected]
Format settings, CABAC                   : Yes
Format settings, ReFrames                : 4 frames
Codec ID                                 : V_MPEG4/ISO/AVC
Duration                                 : 3h 2mn
Nominal bit rate                         : 1 048 Kbps
Width                                    : 1 280 pixels
Height                                   : 720 pixels
Display aspect ratio                     : 16:9
Frame rate                               : 24.000 fps
Color space                              : YUV
Chroma subsampling                       : 4:2:0
Bit depth                                : 8 bits
Scan type                                : Progressive
Bits/(Pixel*Frame)                       : 0.047
Writing library                          : x264 core 125 r2200 999b753
Encoding settings                        : cabac=1 / ref=3 / deblock=1:-1:-1 / analyse=0x3:0x113 / me=umh / subme=9 / psy=1 / psy_rd=0.00:0.00 / mixed_ref=1 / me_range=32 / chroma_me=1 / trellis=2 / 8x8dct=1 / cqm=0 / deadzone=21,11 / fast_pskip=0 / chroma_qp_offset=0 / threads=48 / lookahead_threads=8 / sliced_threads=0 / nr=0 / decimate=1 / interlaced=0 / bluray_compat=0 / constrained_intra=0 / bframes=3 / b_pyramid=2 / b_adapt=2 / b_bias=0 / direct=3 / weightb=1 / open_gop=0 / weightp=2 / keyint=250 / keyint_min=25 / scenecut=40 / intra_refresh=0 / rc_lookahead=60 / rc=2pass / mbtree=1 / bitrate=1048 / ratetol=1.0 / qcomp=0.60 / qpmin=10 / qpmax=51 / qpstep=4 / cplxblur=20.0 / qblur=0.5 / ip_ratio=1.40 / aq=1:1.00
Default                                  : Yes
Forced                                   : No

And another video,

ID                                       : 1
Format                                   : AVC
Format/Info                              : Advanced Video Codec
Format profile                           : [email protected]
Format settings, CABAC                   : Yes
Format settings, ReFrames                : 4 frames
Codec ID                                 : V_MPEG4/ISO/AVC
Duration                                 : 1h 30mn
Nominal bit rate                         : 817 Kbps
Width                                    : 1 280 pixels
Height                                   : 544 pixels
Display aspect ratio                     : 2.35:1
Frame rate                               : 23.976 fps
Color space                              : YUV
Chroma subsampling                       : 4:2:0
Bit depth                                : 8 bits
Scan type                                : Progressive
Bits/(Pixel*Frame)                       : 0.049
Writing library                          : x264 core 120 r2146 bcd41db
Encoding settings                        : cabac=1 / ref=3 / deblock=1:-1:-1 / analyse=0x3:0x113 / me=umh / subme=9 / psy=1 / psy_rd=0.00:0.00 / mixed_ref=1 / me_range=32 / chroma_me=1 / trellis=2 / 8x8dct=1 / cqm=0 / deadzone=21,11 / fast_pskip=0 / chroma_qp_offset=-2 / threads=12 / sliced_threads=0 / nr=0 / decimate=1 / interlaced=0 / bluray_compat=0 / constrained_intra=0 / bframes=3 / b_pyramid=2 / b_adapt=2 / b_bias=0 / direct=3 / weightb=1 / open_gop=0 / weightp=2 / keyint=240 / keyint_min=23 / scenecut=40 / intra_refresh=0 / rc_lookahead=60 / rc=2pass / mbtree=1 / bitrate=817 / ratetol=1.0 / qcomp=0.60 / qpmin=10 / qpmax=51 / qpstep=4 / cplxblur=20.0 / qblur=0.5 / ip_ratio=1.40 / aq=1:1.00
Default                                  : Yes
Forced                                   : No

How do you know which video is better?

1
  • For video, color fidelity is a major factor for perceived "video quality". None of the digital video properties you list, other than bit depth, actually control that. Spatial resolution and its temporal cousin, frame rate, are over-hyped by equipment manufacturers as having direct & significant relationship with "quality". The GIF versus JPEG debates pretty much showed that "more colors" was better than "more resolution".
    – sawdust
    Aug 13, 2012 at 2:36

2 Answers 2

4

The one factor that will give you a good idea of video quality, regardless of height/width/framerate/depth, is bits/pixel*frame or bpf. This is a composite measurement which includes the codec settings, frame size and framerate. i.e.

Bits/(Pixel*Frame)                       : 0.047

For example, in an uncompressed, 24-bit RGB video, the bpf would be 24.0 bits, because there's no compression. In your first example, compression/encoding has rendered the bpf much, much lower, at only 0.047.

  • In general, assuming your codec is AVC or MPEG-4 ASP (Xvid/Divx), a bpf of 0.1 or more is good, 0.2 or more is very good, and 0.3 or more is excellent. This holds true for most real-life moving video, and less true for pure animations. Of course, if your "movie" is simply a slideshow of one picture every 10 seconds, this assumption completely falls apart.

  • Also, assuming a similar codec and bpf, then the video with a better height/width/framerate is naturally going to be "better" if your output screen/TV can support that resolution/framerate.

2
  • I would have to disagree with this. bpf doesn't tell you much if you are comparing two videos of different resolutions or frame rates. If you are comparing videos of the same resolution and frame rate, you might as well use the total bitrate, which is usually obtained much more conveniently. Aug 14, 2012 at 3:28
  • Bjorn, I think izx is probably right. Bits per pixel is probably the closest thing you'll get to an accurate comparison between videos. I believe videos encoded at the same quality will have a similar BPF even if they have different framerates and resolutions, even though their total bitrate will be completely different.
    – Simon E.
    Nov 17, 2012 at 2:59
1

The subjective "quality" of a compressed audio or video file is the result of many factors and there is no simple formula. Some compression schemes will be better for animation, and others for highly complex video footage. Whether you prefer a highly compressed video of high resolution or a video with low compression and low resolution, for example, depends, and is highly subjective.

3
  • But its still can be compared! Dont just mention many factors. Mention 3-4 factors. Other factors can be kept constant. If not assume it constant. Aug 12, 2012 at 11:49
  • Well, the major factors are, as you mentioned already, Resolution (the width and height of the video), frame rate, codec (aka encoding), and bit rate, which is inversely correlated with the compression ratio. I would say the bit depth is less important, but that assumes a reasonable bit depth to begin with, and, of course, it depends.For audio, bit depth, sample rate, compression ratio and codec are the major factors. Again bit depth above 16 bits is not going to make much difference.
    – Bjorn Roche
    Aug 12, 2012 at 15:09
  • If you are looking for one number, the bitrate is probably as close as you will get, but that won't always work. Aug 14, 2012 at 3:30

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .