How to set quality(programmatically) on a GstEncodingProfile?
waldemar
valdemar at gmail.com
Wed Sep 16 14:23:10 PDT 2015
Hi guys!
I'm using a GstEncodingProfile to save an mp4 video. I'm creating the
profile programmatically (to give it to a GES Pipeline). The file has the
right encoding for audio and video, but I still cannot set the quality
(speed-preset?) to have a smaller file size cuz the one I'm getting is
huuge.
Here's the code I'm using to create the encoding profile:
// MPEG-4 audio h264 in mp4
// video/quicktime,variant=iso:video/x-h264:audio/mpeg,mpegversion=4
LOG_DEBUG("Setting encoding to
video/quicktime,variant=iso:video/x-h264:audio/mpeg,mpegversion=4",
LOGGER_PIPELINE);
container = gst_encoding_container_profile_new ("mp4", NULL,
gst_caps_new_simple ("video/quicktime", "variant",
G_TYPE_STRING, "iso",
NULL), NULL);
gst_encoding_container_profile_add_profile (container,
(GstEncodingProfile *)
gst_encoding_video_profile_new (gst_caps_new_empty_simple
("video/x-h264"), NULL, NULL, 1));
gst_encoding_container_profile_add_profile (container,
(GstEncodingProfile *)
gst_encoding_video_profile_new (gst_caps_new_simple
("video/x-h264",
"base-profile", G_TYPE_STRING, "lc", NULL), NULL, NULL, 1));
gst_encoding_container_profile_add_profile (container,
(GstEncodingProfile *)
gst_encoding_audio_profile_new (gst_caps_new_simple
("audio/mpeg",
"mpegversion", G_TYPE_INT, 4, NULL), NULL, NULL, 1));
Thank you guys!
--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/How-to-set-quality-programmatically-on-a-GstEncodingProfile-tp4673665.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.
More information about the gstreamer-devel
mailing list