FPGA Image Signal Processor - GStreamer Pipelines - GeometricTransformationUnit

From RidgeRun Developer Connection
Jump to: navigation, search


Previous: GStreamer_Pipelines/HistogramEqualizer Index Next: GStreamer_Pipelines/Undistort




GStreamer Pipelines

The following pipelines must be run after loading the transformation matrix into the accelerator.

With a videotestsrc

Source

This pipeline generates a video test sequence in GRAY8 and sends it to the Accelerator. This can be applicable when using the ARGB version.

gst-launch-1.0 videotestsrc is-live=true ! "video/x-raw,width=72,height=72" ! v4l2sink sync=false device=/dev/video2 -v

Sink

This pipeline receives the GRAY8 video sequence transformed and shows it in a display. The videoconvert performs a conversion from GRAY8 to a manageable format for xvimagesink. This also works for the ARGB version thanks to the auto-negotiation.

gst-launch-1.0 v4l2src device=/dev/video1 ! "video/x-raw,width=640,height=480" ! videoconvert ! xvimagesink sync=false -v

Please, pay attention to the devices:

/dev/video1: output port device
/dev/video2: input port device

With a camera

These pipelines were tested in a camera that already has a demosaicing process provided by the NVIDIA ISP and runs on NVIDIA Xavier.

Source

The nvarguscamerasrc captures the image from a camera connected to the NVIDIA Xavier and performs the demosaicing process. The videoconvert is used to convert the color image to grayscale. Also, the tee allows us to see the original image.

gst-launch-1.0 nvarguscamerasrc wbmode=off awblock=true aelock=true ! "video/x-raw(memory:NVMM),width=72,height=72" ! nvvidconv ! videoconvert ! "video/x-raw,format=GRAY8" ! tee name=t t. ! queue ! v4l2sink device=/dev/video2 -v t. ! queue ! videoconvert ! xvimagesink

Sink

To receive the video sequence back from the accelerator, you can use the following pipeline:

gst-launch-1.0 v4l2src device=/dev/video1 ! "video/x-raw,width=640,height=480" ! videoconvert ! xvimagesink sync=false -v

This is the same pipeline used for the videotestsrc example.



Previous: GStreamer_Pipelines/HistogramEqualizer Index Next: GStreamer_Pipelines/Undistort