# Camera
Source: [https://docs.qualcomm.com/doc/80-70014-50/topic/camera.html](https://docs.qualcomm.com/doc/80-70014-50/topic/camera.html)
The QIM SDK camera plugin, camsrc, acts a client to Qualcomm camera service. The
camera use cases show the execution and display of 1080p YUV streams from a live source.
For more information on the camera plugin, see [camera
architecture](https://docs.qualcomm.com/doc/80-70014-50/topic/camera-arch.html).
## Prerequisites
Ensure that you complete the preconditions mentioned in [Multimedia use cases](https://docs.qualcomm.com/doc/80-70014-50/topic/multimedia-use-cases.html).
Run the following commands:
mount -o remount,rw /Copy to clipboard
export XDG_RUNTIME_DIR=/dev/socket/westonCopy to clipboard
export WAYLAND_DISPLAY=wayland-1Copy to clipboard
## Single 1080p YUV stream from live source
Run the following command to execute the pipeline:
gst-launch-1.0 qtiqmmfsrc name=camsrc video_0::type=preview ! video/x-raw\(memory:GBM\),format=NV12,width=1920,height=1080,framerate=30/1,compression=ubwc ! waylandsink fullscreen=true async=true sync=false
Copy to clipboard
The content from camera stream should be seen on the display.
To stop the use case, press CTRL + C.
The pipeline shows a single 1080p stream taken from the camera and sent to
display.

## Three 1080p YUV streams from live source
Run the following command to execute the use case:
gst-launch-1.0 -e qtiqmmfsrc name=camsrc video_0::type=preview ! video/x-raw\(memory:GBM\),format=NV12,width=1920,height=1080,framerate=30/1,compression=ubwc ! waylandsink x=0 y=0 width=500 height=400 async=true sync=false camsrc. ! video/x-raw\(memory:GBM\),format=NV12,width=1920,height=1080,framerate=30/1,compression=ubwc ! waylandsink x=510 y=0 width=500 height=400 async=true sync=false camsrc. ! video/x-raw\(memory:GBM\),format=NV12,width=1920,height=1080,framerate=30/1,compression=ubwc ! waylandsink x=0 y=410 width=500 height=400 async=true sync=falseCopy to clipboard
The content from camera streams should be seen on the display.
To stop the use case, press CTRL + C.
The pipeline shows three 1080p streams taken from the camera and sent to display with
each stream displayed at different positions on the screen.

## Request multiple streams with different FPS from camera
Run the commands to execute the following use cases:
- Two streams with capture request mode at 30 fps/15
fps:
gst-launch-1.0 -e --gst-debug=fpsdisplaysink:6 qtiqmmfsrc name=qmmf frc-mode=capture-request video_0::type=preview ! video/x-raw\(memory:GBM\),format=NV12,width=1920,height=1080,framerate=30/1,compression=ubwc ! fpsdisplaysink name=disp1 signal-fps-measurements=true text-overlay=false video-sink="fakesink" qmmf. ! video/x-raw\(memory:GBM\),format=NV12,width=1920,height=1080,framerate=15/1,compression=ubwc ! fpsdisplaysink name=disp2 signal-fps-measurements=true text-overlay=false video-sink="fakesink"Copy to clipboard
- Two streams with capture request mode at 17 fps/10
fps:
gst-launch-1.0 -e --gst-debug=fpsdisplaysink:6 qtiqmmfsrc name=qmmf frc-mode=capture-request video_0::type=preview qmmf.video_0 ! video/x-raw\(memory:GBM\),format=NV12,width=1920,height=1080,framerate=17/1,compression=ubwc ! fpsdisplaysink name=disp1 signal-fps-measurements=true text-overlay=false video-sink="fakesink" qmmf.video_1 ! video/x-raw\(memory:GBM\),format=NV12,width=1920,height=1080,framerate=10/1,compression=ubwc ! fpsdisplaysink name=disp2 signal-fps-measurements=true text-overlay=false video-sink="fakesink"Copy to clipboard
- Two streams with capture request mode at 5 fps/25 fps:
The smaller frame rate
is processed first and camera updates the frame rate on the second
stream.
gst-launch-1.0 -e --gst-debug=fpsdisplaysink:6 qtiqmmfsrc name=qmmf frc-mode=capture-request video_0::type=preview qmmf.video_0 ! video/x-raw\(memory:GBM\),format=NV12,width=1920,height=1080,framerate=5/1,compression=ubwc ! fpsdisplaysink name=disp1 signal-fps-measurements=true text-overlay=false video-sink="fakesink" qmmf.video_1 ! video/x-raw\(memory:GBM\),format=NV12,width=1920,height=1080,framerate=25/1,compression=ubwc ! fpsdisplaysink name=disp2 signal-fps-measurements=true text-overlay=false video-sink="fakesink"Copy to clipboard
## Set sensor mode
Use the following command to set the sensor mode in the camsrc plugin:
export GST_PLUGIN_PATH=/usr/lib/gstreamer-1.0 && gst-launch-1.0 qtiqmmfsrc camera=0 name=camsrc sensor-mode=