| ▲ | mikepavone 7 hours ago | |||||||||||||||||||||||||||||||||||||
> They shared the polling code in the article. It doesn't request another jpeg until the previous one finishes downloading. You're right, I don't know how I managed to skip over that. > UDP is not necessary to write a loop. True, but this doesn't really have anything to do with using JPEG either. They basically implemented a primitive form of rate control by only allowing a single frame to be in flight at once. It was easier for them to do that using JPEG because they (to their own admission) seem to have limited control over their encode pipeline. | ||||||||||||||||||||||||||||||||||||||
| ▲ | londons_explore 6 hours ago | parent [-] | |||||||||||||||||||||||||||||||||||||
> have limited control over their encode pipeline. Frustratingly this seems common in many video encoding technologies. The code is opaque, often has special kernel, GPU and hardware interfaces which are often closed source, and by the time you get to the user API (native or browser) it seems all knobs have been abstracted away and simple things like choosing which frame to use as a keyframe are impossible to do. I had what I thought was a simple usecase for a video codec - I needed to encode two 30 frame videos as small as possible, and I knew the first 15 frames were common between the videos so I wouldn't need to encode that twice. I couldn't find a single video codec which could do that without extensive internal surgery to save all internal state after the 15th frame. | ||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||