An open API service indexing awesome lists of open source software.

https://github.com/qengineering/gstreamer-1.18.4-rpi_64-bits

GStreamer 1.18.4 with OpenCV example on a Raspberry Pi 4
https://github.com/qengineering/gstreamer-1.18.4-rpi_64-bits

cpp gstreamer gstreamer-pipeline opencv raspberry-pi raspberry-pi-64-os raspberry-pi-camera raspicam

Last synced: 5 months ago
JSON representation

GStreamer 1.18.4 with OpenCV example on a Raspberry Pi 4

Awesome Lists containing this project

README

        

# GStreamer-1.18.4-RPi_64-bits
![output image]( https://qengineering.eu/images/GStreamer_32_30FPS.webp )

## GStreamer + OpenCV on a Raspberry Pi 4
[![License](https://img.shields.io/badge/License-BSD%203--Clause-blue.svg)](https://opensource.org/licenses/BSD-3-Clause)


An working example of the GStreame 1.18.4.

It works on a Raspberry Pi with an 64-bits OS.

If you want to use the new 32-bits **rpicamsrc** see https://github.com/Qengineering/GStreamer-1.18.4-RPi_32-bits

------------

## Dependencies.

To run the application, you have to:
- A Raspberry Pi 4.
- GStreamer 1.18.4 installed. [Install GStreamer](https://qengineering.eu/install-gstreamer-1.18-on-raspberry-pi-4.html)

- OpenCV 64 bit installed. [Install OpenCV 4.5](https://qengineering.eu/install-opencv-4.5-on-raspberry-64-os.html)

- Code::Blocks installed. (```$ sudo apt-get install codeblocks```)
- A working Raspicam or Webcam

------------

## Installing the app.
To extract and run the app in Code::Blocks

$ mkdir *MyDir*

$ cd *MyDir*

$ wget https://github.com/Qengineering/GStreamer-1.18.4-RPi_64-bits/archive/refs/heads/main.zip

$ unzip -j master.zip

Remove master.zip, LICENSE and README.md as they are no longer needed.

$ rm master.zip

$ rm LICENSE

$ rm README.md


Your *MyDir* folder must now look like this:

GStreamerTest64.cpb

main.cpp

------------

## Running the app.
To run the application load the project file GStreamerTest64.cbp in Code::Blocks.

Next, follow the instructions at [Hands-On](https://qengineering.eu/deep-learning-examples-on-raspberry-32-64-os.html#HandsOn).

On this [page](https://qengineering.eu/install-gstreamer-1.18-on-raspberry-pi-4.html) you can see how to make the **webcam** work.

------------

## Frame rate.
The Raspicam supports many sizes and frame rates, as you can see [here](https://www.raspberrypi.org/documentation/raspbian/applications/camera.md).

You can switch between the different options by altering the parameters in the pipeline.

As long it's a valid combination, it will work. For instance:

```
//pipeline parameters
int capture_width = 640 ;
int capture_height = 480 ;
int display_width = 640 ;
int display_height = 480 ;
int framerate = 90 ;
```

![output image]( https://qengineering.eu/images/GStreamer_32_90FPS.webp )

------------

[![paypal](https://qengineering.eu/images/TipJarSmall4.png)](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=CPZTM5BB3FCYL)