How to encode and decode image stream frame by frame

92 views
Skip to first unread message

Sean Scheideman

unread,
Jan 3, 2017, 8:37:23 PM1/3/17
to AVBlocks
I am trying to create a video streaming application, where I receive image frames from a usb camera, then encode them using H264. Then I send them to a server and decode them. 

Currently I am pushing frames into a H264 transcoder, then pulling the encoded frames and sending them to the the server. On the server side I push the encoded frames into the decoder and the try to pull, but this fails. 

I am wondering if I am doing this the right way and if this use case is supported? I see there is a previous post from 6/12/13: Decoding with push pull, where a PullPushDecoder sample is referenced, but there is no PullPushDecoder sample for the current version.

Attached are my encoding and decoding implementations. The server is a cpp app and the client is a C# app.

Thanks,

Sean 
AVBlocksEncoding.cpp
AVBlocksEncoding.h
AVBlocksDecoding.cs

VK

unread,
Jan 3, 2017, 9:08:47 PM1/3/17
to AVBlocks
Hi Sean,

On the decoding side likely you need to call Push multiple times before you can get something out of Pull.

Thanks    
Valentin Kantchev

VK

unread,
Jan 3, 2017, 9:12:24 PM1/3/17
to AVBlocks
On Tuesday, January 3, 2017 at 5:37:23 PM UTC-8, Sean Scheideman wrote:

Sean Scheideman

unread,
Jan 5, 2017, 2:29:37 PM1/5/17
to avbl...@googlegroups.com
Thanks! Not pushing multiple times was the issue.

Reply all
Reply to author
Forward
0 new messages