pngenc: make setcaps more robust, use gstvideo functions
authorRené Stadler <mail@renestadler.de>
Sun, 16 Oct 2011 17:41:28 +0000 (19:41 +0200)
committerRené Stadler <rene.stadler@collabora.co.uk>
Fri, 21 Oct 2011 08:25:08 +0000 (10:25 +0200)
commit9eb55c3d8feff7ef496cd66551b4275d23eb40eb
tree302144ce2c2c7c25c23e95b04bbded7417e4aff0
parent5baca05ec38e507352a178b5faf4eed1d85e1479
pngenc: make setcaps more robust, use gstvideo functions

A setcaps function needs to actually verify the caps carefully. In this case,
it was possible to e.g. link a video decoder with YUV+RGB template caps to
pngenc.  That would cause a crash when the decoder pushes a YUV buffer. Same
thing when pushing a valid buffer that exceeds the resolution limits.

Also, missing framerate caps field would cause a glib critical warning due to
invalid GValue. This fails hard now.
ext/libpng/Makefile.am
ext/libpng/gstpngenc.c
ext/libpng/gstpngenc.h