Netflix was one of the first streaming services, so naturally it’s well versed in the world of streaming connection. It makes sense then it figured out one of the main issues with streaming—buffering when there is a bad connection.

How did it managed to do this? It uses Google’s VP9 codec to encode video depending on simple and complex scenes.

That sounds dead simple but it’s a little more complicated. Networks have gotten really good here in the U.S. so consumers in this region don’t suffer too much from bad connections (for the most part). But Netflix has been pushing for a global roll out, and in developing countries, bad connections are often too common. This means a lot of buffering.

Netflix demoed a video of Stranger Things on a Nexus 6P at an event in front of many journalist. The video looked grainy and unimpressive, but what was impressive was that this video stream was on a 100kbps connection. This was due to the encoding Netflix has been working hard to improve.

A scene with a lot of moving elements, take for instance an action scene from Superman Returns will use much more data than one in BoJack Horseman with its simple animated scenes. To overcome for the difference, Netflix created a machine learning algorithm that uses data more responsibly.

“You don’t need that many bits to get high definition from BoJack when it’s simple animation,” stated Netflix VP of product Todd Yellin. “We started looking at the title and how complex the visuals were and how many bits we would need for high definition and standard definition. And we were able to take BoJack and decrease way down the number of bits we would do for an HD stream or an SD stream.”

This is the key to shifting between a high bandwidth encode on a high-speed LTE connection or bad connection that gets as slow as 100kbps. This ensures that video playback doesn’t stutter or stop while the encode changes in the background.

This is pretty damn impressive

Netflix is not only working hard on creating an expansive catalog of content, it’s also working hard to ensure that the backend of its service is also up to par. When people think of Netflix they just think of all the shows and movies they watch on it. Little to their knowledge, Netflix is making sure it can keep its streams going strong even in poor connection.

This not only bodes well for the streaming giant as it continues to roll out its service globally, it’s also good to know as a Netflix consumer that my streaming connection won’t give out even when I’m in a spotty area.