c++ - image data as source in gstreamer -
i want make gstreamer application takes image data source instead of file location. intention display image received through tcp. when tcp got image data(byte array) should pass data gstreamer plugin directly out saving locally.
the multifilesrc should work.
description
reads buffers sequentially named files. if used image decoder, 1 needs use "caps" property or capsfilter force caps containing framerate. otherwise image decoders send eos after first picture. need videorate element set timestamps on buffers after first 1 in accordance framerate.
file names created replacing "%d" index using printf().
example launch line
gst-launch-1.0 multifilesrc location="img.%04d.png" index=0 caps="image/png,framerate=\(fraction\)12/1" ! \ pngdec ! videoconvert ! videorate ! theoraenc ! oggmux ! \ filesink location="images.ogg"this pipeline creates video file "images.ogg" joining multiple png files named img.0000.png, img.0001.png, etc.
so if using gstreamer command line should trick. need speficiy file , "loop" on file when received.
otherwise it's not complicated code gstreamer pipeline use multifilesrc source.
Comments
Post a Comment