You need to use helper class with following function

void MyCameraClass::setCamera(QObject *camera) { QMediaObject *mediaObject = camera ? qobject_cast(camera->property("mediaObject").value()) : 0; if (mediaObject && mediaObject->service()) { QVideoEncoderSettingsControl *videoEncoder = mediaObject->service()->requestControl(); if (videoEncoder) { QVideoEncoderSettings settings = videoEncoder->videoSettings(); settings.setEncodingOption(QLatin1String("preset"), QLatin1String("vga")); videoEncoder->setVideoSettings(settings); } } }

Export that class to QML and call BEFORE camera active first time. Pass QML Camera object id to function

function changeCameraPreset(camera) { MyCameraClass.setCamera(camera) }

For loading preset you need to ccreate preset file

GstOMXH264Enc-omxh264enc.prs

for matroska container

[_presets_] version=0.10 element-name=GstOMXH264Enc-omxh264enc [vga] control-rate=1 target-bitrate=2000000

GstOMXMPEG4VideoEnc-omxmpeg4videoenc.prs

for mp4 container

[_presets_] version=0.10 element-name=GstOMXMPEG4VideoEnc-omxmpeg4videoenc [vga] control-rate=1 target-bitrate=2000000

Last thing is registering preset folder for your application. Add following code to your main function:

gst_init(0, 0); gst_preset_set_app_dir("/usr/share/your-app-name/presets");

And setup your presets deploy path to this destinaton

Big thanks to Andrew den Exter for consultation