[longomatch] Prefer Fluendo audio encoders when those are available
- From: Andoni Morales Alastruey <amorales src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [longomatch] Prefer Fluendo audio encoders when those are available
- Date: Wed, 5 Nov 2014 19:02:37 +0000 (UTC)
commit c5ca6f5b8cf82f944e01bbd101651e4363eb1df3
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date: Mon Nov 3 12:31:01 2014 +0100
Prefer Fluendo audio encoders when those are available
libcesarplayer/video-utils.m | 18 ++++++++++++++----
1 files changed, 14 insertions(+), 4 deletions(-)
---
diff --git a/libcesarplayer/video-utils.m b/libcesarplayer/video-utils.m
index 0cb71db..ec67ad6 100644
--- a/libcesarplayer/video-utils.m
+++ b/libcesarplayer/video-utils.m
@@ -330,14 +330,24 @@ lgm_create_audio_encoder (AudioEncoderType type, guint quality,
switch (type) {
case AUDIO_ENCODER_MP3:
- encoder = gst_element_factory_make ("lamemp3enc", "audio-encoder");
- g_object_set (encoder, "target", 0, "quality", (gfloat) 4, NULL);
+ encoder = gst_element_factory_make ("flump3enc", "audio-encoder");
+ if (encoder != NULL) {
+ g_object_set (encoder, "bitrate", 128, NULL);
+ } else {
+ encoder = gst_element_factory_make ("lamemp3enc", "audio-encoder");
+ g_object_set (encoder, "target", 0, "quality", (gfloat) 4, NULL);
+ }
name = "Mp3 audio encoder";
break;
case AUDIO_ENCODER_AAC:
- encoder = gst_element_factory_make ("faac", "audio-encoder");
- g_object_set (encoder, "bitrate", 128000, NULL);
+ encoder = gst_element_factory_make ("fluaacenc", "audio-encoder");
+ if (encoder != NULL) {
+ g_object_set (encoder, "bitrate", 128, "output-format", 2, NULL);
+ } else {
+ encoder = gst_element_factory_make ("faac", "audio-encoder");
+ g_object_set (encoder, "bitrate", 128000, NULL);
+ }
name = "AAC audio encoder";
break;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]