how to control the camera settings while it is running?

Hi all! I have susscessfully run the camera by the command:

gst-launch-1.0 nvarguscamerasrc wbmode=4 saturation=1 ! ‘video/x-raw(memory:NVMM), width=(int)1920, height=(int)1080, format=(string)NV12, framerate=(fraction)30/1’ ! nvvidconv flip-method=0 ! ‘video/x-raw, width=960, height=616’ ! nvvidconv ! nvegltransform ! nveglglessink -e

and also control the awb and saturation by the command below.

But I have no idea that how can I change the values(wbmode, saturation and so on) during the camera is running.

Please give me so advisement, thank you so much!

If you install and build tegra_multimedia_api there is a very convenient application, argus_camera, that allows you to change values on a live stream. Best of all all of the source code is available so it’s easy to adapt to your own needs and incorporate into your own applications.

You may have the source code already, look in /usr/src/tegra_multimedia_api.

I use this script to build the code on the systems I use. I’ve also attached the script.

#!/bin/bash

SRC_DIR='/usr/src/tegra_multimedia_api'
DEST_DIR="$HOME/"

check_src()
{
    if ! [ -d "$SRC_DIR" ]; then
	echo 'You must install the Tegra Multimedia API on the target.'
	echo 'This can be done via SDK Manager'
	exit 1
    fi
}

install_deps()
{
    sudo apt-get -y install \
	 cmake \
	 build-essential \
	 pkg-config \
	 libx11-dev \
	 libgtk-3-dev \
	 libexpat1-dev \
	 libjpeg-dev \
	 libgstreamer1.0-dev \
	 gcc-6
}

copy_src()
{
    cp -r "$SRC_DIR" "$DEST_DIR"
}

perf_max()
{
    sudo nvpmodel -m 0
    sudo jetson_clocks
}

n_cpus()
{
    grep -c ^proc /proc/cpuinfo
}

build()
{
    pushd "${DEST_DIR}/tegra_multimedia_api/argus"
    mkdir build
    cd build
    cmake ..
    make -j$(n_cpus)
    sudo make install
    popd
}

check_src
install_deps
copy_src
perf_max
build

build-tm-api.sh.txt (799 Bytes)

Hi D3_growe :

Thank you so much!According to your guidance, I think I have found the right way to develop the isp control on Jetson platform.We can develop the applications based on the samples which is in the file ‘argus’ after you build this file and make.

Best Regards

That’s great! I’m glad it’s all working for you now.