Menu English Ukrainian russian Home

Free technical library for hobbyists and professionals Free technical library


BOOKS AND ARTICLES
Free library / Directory / video art

MPEG-2 and home video

video art

Directory / video art

Comments on the article Comments on the article

Preliminary remarks

In the "MPEG-world" it is customary to express the speed of the video data stream not in megabytes / sec, but in kilobits / sec. In order not to mix different speeds, all further values ​​are given in kilobits / sec.

Everyone has different quality requirements. This is clearly seen in the "audio world": young people (of a certain kind, I will not delve into the classification ...) listen to $200 boomboxes at a wild volume and "stick out", and audiophiles listen to a $2000 component system and sigh - "the upper is not transparent enough middle". The same is with the video, so all the following quality ratings reflect my personal opinion of the "advanced teapot" and I do not intend to enter into any disputes with either the "lamers" or the "professionals"! I also deliberately simplified the "theory" and do not teach me what "really" MPEG-2 encoding is.

Experiments with JPEGs. Start

Experimenting with real movies takes a noticeable amount of time, so the basic patterns are much quicker and easier to illustrate with still images. Take a high-quality "uncompressed" TIFF, "natural" (for example, a landscape), with a sufficient number of sharp edges and small details, about 600x800 in size (to view on the screen in 100% mode). In it, the color of each point is encoded separately, "to be honest." This is the maximum (reference) quality within the 24-bit color model. But the human eye has some features, and does not perceive all the information, and therefore it is possible to delete (forever!) Part of the data without a noticeable loss of quality (JPEG format).

In Photoshop or even in ACDSee, try to compress the picture with different "quality" parameters and find the ratio of the sizes of the original file and JPEG, in which the distortion is still almost imperceptible. You will get a coefficient in the range of 10-25, depending on the picture and your "strictness". At higher compression, the artifacts are clearly noticeable (colored halos, square structure), but in dynamics this "disgrace" also moves ... Now compress with another program. Most likely there will be no noticeable difference in the value of the threshold coefficient. Maximum - 10-20%. I dare to say that it is impossible (and in the future) to increase this coefficient at times - miracles do not happen, information does not disappear anywhere, it is impossible to fit all the richness of the landscape into a few bytes ... All fractal toys like to be shown on specially selected source pictures, and speech is here is about a random, arbitrary image.

What follows from here for the video? The resolution of the video signal is determined by the TV standard, its "computer" analogue is approximately 720x576. From here, at 25 frames per second, we get approximately 250 kbps ("uncompressed" video). Apply to each JPEG frame with the same "safe" factor of 000-10. We get 25-10000 kbps (depending on the original). As you know, the DV-format is analogous to JPEG-compression, and its stream is 25000 (do you know? - to be sure for any original). Thus, in most cases, further frame-by-frame compression of the DV format is impractical, because leads to noticeable artifacts.

Why MPEG is more compact and what is needed for this

It turns out that 20000-30000 kbps is the limit? That's 3-4 minutes on a CD-R and 20-30 minutes on a DVD. Strictly speaking, for any arbitrary image from frames independent of each other - YES! But what about the excellent quality of DVD (5000-8000)? Answer: in real movies, consecutive frames are usually interdependent and the MPEG format uses this. Roughly speaking, we do not compress every frame in JPEG, but the difference between adjacent frames. Since the camera in professional films is always on a tripod or on rails, often the background changes are insignificant or monotonous, and therefore easily squeezed. Dynamic scenes (explosions, etc.) usually "take" the speed from "calm" pieces due to the use of a variable bitrate...

Let's imagine what a difference frame looks like for an object moving against a stationary background (using a tripod). Obviously, the entire background is a solid plane (black in the RGB model), and only a small part of the frame ("object") has a color contrasting with the background. Let's get back to experimenting with JPEGs in Photoshop. Pick a similar picture yourself and try it - the results are impressive... So, I picked up a picture from Berlin (a fragment of a photo from the "Europe-98" album) - a solid background (sky) and a small contrasting object. Dimensions 720x546. It looks something like this:

MPEG-2 and home video

Next, I compressed it into JPEG so that the artifacts just started to appear. It turned out 12K. After that, the same type of operation was performed three times: the "add noise" filter (with different noise values) was applied to the original image (uncompressed) and then it was compressed to JPEG so that it turned out to be 12K. Fragments of what happened:

MPEG-2 and home video

You can clearly see what "wild" artifacts appear on the noisy picture after compression. Not very good on fragments, but on the whole frame (or better, on several), you can see that even noise of 20 units on an uncompressed image is practically not annoying. It is somehow filtered by our eyes and we still clearly imagine what kind of object it is (the same thing happens when we watch an old VHS tape or listen to a cassette on a tape recorder). On the contrary - compression artifacts, rough stripes and squares are annoying, and the eye "does not want to get used to them." So that the artifacts do not grow with noise, you have to reap not with the same size, but with the same "quality". Then the dimensions grow noticeably with increasing noise. In this example, with the same "quality" parameter, approximately the following size line was obtained: 12:24:36:48.

What does this mean for video? Only the fact that the bitrate value itself is not a guarantee of high quality, a lot depends on the quality of the source material. For example, if the source material contains noise, then in order to avoid artifacts, you have to increase the bitrate several times ...

Under ideal conditions for professional DVD production, MPEG-2 gives a gain (over JPEG) of about 4-5 times (let's call it "MPEG-additive"). Once again, we formulate these ideal conditions in the form of a table:

Condition Pros We are lovers
Camera color noise Short. Professional cameras for tens of thousands of dollars differ from amateur cameras for 600 not so much in resolution (it is almost the same) and color reproduction (it is better, but does not determine the price). They are distinguished by a large (not by pixels!) matrix - and, accordingly, very low noise Tall, especially indoors. Matrices of most cameras are only 1/6"
background jitter Completely missing. Tripods, rails, shoulder cameras It is always present, especially with light cameras and at long focuses ...
Lighting It is set on purpose, even night scenes are usually shot with backlighting and "shaded" later, during editing Often not controlled by the operator at all. As a result, at dusk and indoors, the matrix operates with increased noise.
Intermediate compression, which can also be considered as a little noise None - uncompressed original is encoded in MPEG DV compression is present by definition...

I admit the idea that further improvement of the algorithms will increase the "MPEG-supplement" one and a half times, but most likely not more. By the way, despite the hype, MPEG4 is slightly better than MPEG2 - by 10 percent at high bitrates. And the notorious DivX compacts, in all honesty, no one will call a real DVD-quality.

And what happens in practice?

Practice shows that "home" video on amateur cameras (due to the failure to fulfill the above conditions, primarily due to noise and shaking) is about twice as bad as professional video, i.e. with the same quality should take up twice as much volume.

The data obtained can be easily presented in the form of a table.

Material JPEG compression (Kj) MPEG additive (Km) Theoretical threshold (250000/Kj/Km), kbit/s Ideal quality (kbps) Tolerable quality (kbps)
Professional, "light" (melodrama, close-up) 20 5 2500 3000-5000 (DVD) 1500-2000 (DivX)
Professional, "difficult" (movies, small parts, explosions) 10 4 6200 6000-8000 (DVD) 3000-4000 (DivX), at 1000-2000 artifacts are already too noticeable, although such discs are sold ...
Amateur, "easy" (e.g. close-ups of children, weddings) 20 2,5 5000 6000-8000 (DVD-R, MPEG-2) 3000-4000 (DivX, 20-30 minutes/CDR)
Amateur, "difficult" (for example, river rapids and waterfalls, or ordinary but very noisy scenes such as digitizing old VHS) 10 2,0 12500 9000 (DVD-R, MPEG-2, with some small artefacts in difficult places) 7000-8000 (DVD-R, MPEG-2)

Conclusions and advice

  1. If a branded melodrama fits an hour into one CD-R, this does not mean that you can stuff your panoramic shots of landscapes and architecture with small details, shot hand-held with a cheap shaking camera from a bus window ... More precisely, you can, but only either 10 minutes, or the worst quality.
  2. MPEG is not a storage medium. At its best, it's the ultimate demo tool (DVD). It is unlikely that it will be possible to remount from it without further losses. To store originals, digital video cassettes (miniDV, D8) are better and easier, and often even cheaper.
  3. MPEG4/DivX is not a panacea and is suitable only for very "smooth" scenes ("slow babies" in close-ups, etc.). It does not provide a revolutionary difference from MPEG2. A small quantitative improvement...
  4. ...and that's why if your masterpieces are short (10-15 minutes), but you still can't wait to burn them to a disc - don't save on discs (spit on DivX), but press them immediately into MPEG2 with a bitrate of 6000-8000 (including .n "DVD-compatible" format). Later, when you buy a DVD-RW, you can easily create a full-fledged DVD based on these clips without re-encoding them, and therefore without losing any more quality.
  5. By the way, DVD-R is no longer a luxury. A device is less than $100, a good blank is less than $2, a "simple" blank is less than $1.
  6. Reaping in MPEG2 is best done with CanopusPr °Coder.
  7. If you plan to shoot your own photos in MPEG, it is useful to remember the table of "ideal conditions" more often - buy and learn how to use a tripod and / or shoulder tripod, do not make sharp "jumps" with the camera, do not get carried away with long handheld focus, pay attention to lighting, etc. P...

Author: Afanasenkov M.A; Publication: pctuner.ru

 We recommend interesting articles Section video art:

▪ Lighting and illumination

▪ Using AVerTV Capture HD in VirtualDub

▪ Assembly workshop for professionals

See other articles Section video art.

Read and write useful comments on this article.

<< Back

Latest news of science and technology, new electronics:

Artificial leather for touch emulation 15.04.2024

In a modern technology world where distance is becoming increasingly commonplace, maintaining connection and a sense of closeness is important. Recent developments in artificial skin by German scientists from Saarland University represent a new era in virtual interactions. German researchers from Saarland University have developed ultra-thin films that can transmit the sensation of touch over a distance. This cutting-edge technology provides new opportunities for virtual communication, especially for those who find themselves far from their loved ones. The ultra-thin films developed by the researchers, just 50 micrometers thick, can be integrated into textiles and worn like a second skin. These films act as sensors that recognize tactile signals from mom or dad, and as actuators that transmit these movements to the baby. Parents' touch to the fabric activates sensors that react to pressure and deform the ultra-thin film. This ... >>

Petgugu Global cat litter 15.04.2024

Taking care of pets can often be a challenge, especially when it comes to keeping your home clean. A new interesting solution from the Petgugu Global startup has been presented, which will make life easier for cat owners and help them keep their home perfectly clean and tidy. Startup Petgugu Global has unveiled a unique cat toilet that can automatically flush feces, keeping your home clean and fresh. This innovative device is equipped with various smart sensors that monitor your pet's toilet activity and activate to automatically clean after use. The device connects to the sewer system and ensures efficient waste removal without the need for intervention from the owner. Additionally, the toilet has a large flushable storage capacity, making it ideal for multi-cat households. The Petgugu cat litter bowl is designed for use with water-soluble litters and offers a range of additional ... >>

The attractiveness of caring men 14.04.2024

The stereotype that women prefer "bad boys" has long been widespread. However, recent research conducted by British scientists from Monash University offers a new perspective on this issue. They looked at how women responded to men's emotional responsibility and willingness to help others. The study's findings could change our understanding of what makes men attractive to women. A study conducted by scientists from Monash University leads to new findings about men's attractiveness to women. In the experiment, women were shown photographs of men with brief stories about their behavior in various situations, including their reaction to an encounter with a homeless person. Some of the men ignored the homeless man, while others helped him, such as buying him food. A study found that men who showed empathy and kindness were more attractive to women compared to men who showed empathy and kindness. ... >>

Random news from the Archive

Created a hybrid of man and sheep 18.02.2018

Biologists from California have grown embryos for the first time, including human and sheep cells.

Work on the creation of chimeras - organisms consisting of genetically heterogeneous cells - has been going on for about a decade and a half. Scientists want to be able to grow full-fledged organs, which could then be transplanted into humans, and which would not be rejected during transplantation. In addition, such experiments could allow for safer testing of new drugs. At the same time, such actions of scientists are rather limited due to discussions about their ethics.

In a new experiment, scientists were able to successfully implant human cells into sheep fetuses at a ratio of about 1 in 10 cells. The embryos successfully developed within 28 days (of which 21 days they were directly inside a living sheep) - as biologists note, this period is enough to understand that they could develop into a full-fledged living organism. After that, the experiment was terminated for ethical reasons.

Human cells were introduced into sheep embryos using CRISPR/Cas9 technology - it allows you to specifically change individual genes in the cells of the body.

The authors of the work emphasize that it remains unclear how exactly human cells can affect the appearance of sheep and the functioning of their nervous system. They expressed the opinion that this requires a longer experiment, which would last at least 70 days. At the same time, scientists emphasize that in any case, in order to grow a full-fledged organ, it is necessary to significantly increase the number of human cells - the ratio with animal cells should be approximately one to a hundred.

A similar experiment was carried out in early 2017 with pigs. The embryos also developed normally for 28 days, the ratio of human and porcine cells was about 1 per 100. After that, they were removed from the body of the sow. Sheep, according to scientists, are more promising for growing human organs than pigs, since experiments have shown that much fewer embryos are needed to successfully create a chimera based on a sheep.

Other interesting news:

▪ Asimo's humanoid robots continue to improve

▪ Smartphone with infinite memory

▪ V-Phone X3 off-road smartphone with 4500 mAh battery

▪ Spiders eat more meat than humans

▪ Advanced SSDs from Intel

News feed of science and technology, new electronics

 

Interesting materials of the Free Technical Library:

▪ site section Power Amplifiers. Article selection

▪ Good Samaritan article. Popular expression

▪ article How did David Copperfield's skills help him avoid a mugging? Detailed answer

▪ article Working on the plucking machine AS-40, AS-XNUMX Befama. Standard instruction on labor protection

▪ article Amplifier on the chip TDA2005, 2x10 watts. Encyclopedia of radio electronics and electrical engineering

▪ article Map hanging in the air. Focus Secret

Leave your comment on this article:

Name:


Email (optional):


A comment:





All languages ​​of this page

Home page | Library | Articles | Website map | Site Reviews

www.diagram.com.ua

www.diagram.com.ua
2000-2024