webrtc_private: Use PA_PROP_XXX defines instead of hard-coded string 93/275593/1
authorSangchul Lee <sc11.lee@samsung.com>
Fri, 27 May 2022 01:32:03 +0000 (10:32 +0900)
committerSangchul Lee <sc11.lee@samsung.com>
Fri, 27 May 2022 01:32:59 +0000 (10:32 +0900)
[Version] 0.3.110
[Issue Type] Improvement

Change-Id: I76d4f7e1af27e01bd8beb2fd2a1e228a77ddbc58
Signed-off-by: Sangchul Lee <sc11.lee@samsung.com>
CMakeLists.txt
packaging/capi-media-webrtc.spec
src/webrtc_private.c

index ec585c10f4ca2737c275c856a3e2f0b32143aa30..569d11bd807c5afe68552bfeeec3395823052c6e 100644 (file)
@@ -11,7 +11,7 @@ SET(INC_DIR include)
 INCLUDE_DIRECTORIES(${INC_DIR})
 
 SET(dependents "dlog glib-2.0 gstreamer-1.0 gstreamer-webrtc-1.0 gstreamer-video-1.0 gstreamer-audio-1.0 \
-                gstreamer-allocators-1.0 json-glib-1.0 iniparser mm-common mm-display-interface capi-media-tool \
+                gstreamer-allocators-1.0 libpulse json-glib-1.0 iniparser mm-common mm-display-interface capi-media-tool \
                 libtbm libwebsockets cynara-client libsmack capi-system-info libsoup-2.4 bundle capi-media-sound-manager")
 IF(NOT TIZEN_PROFILE_TV)
     SET(dependents "${dependents} mm-resource-manager")
index 49cdc0c04ee6351e9451bdd6dbab807f1e01fdc8..e55903605766389d1c90f75caeb0e8ad478697b3 100644 (file)
@@ -1,6 +1,6 @@
 Name:       capi-media-webrtc
 Summary:    A WebRTC library in Tizen Native API
-Version:    0.3.109
+Version:    0.3.110
 Release:    0
 Group:      Multimedia/API
 License:    Apache-2.0
@@ -17,6 +17,7 @@ BuildRequires:  pkgconfig(gstreamer-webrtc-1.0)
 BuildRequires:  pkgconfig(gstreamer-video-1.0)
 BuildRequires:  pkgconfig(gstreamer-audio-1.0)
 BuildRequires:  pkgconfig(gstreamer-allocators-1.0)
+BuildRequires:  pkgconfig(libpulse)
 BuildRequires:  pkgconfig(appcore-efl)
 BuildRequires:  pkgconfig(elementary)
 BuildRequires:  pkgconfig(json-glib-1.0)
index 7081997e2f20e9c8d9abd455d012329e37ffc250..85276d8c0160cc24d9be7d2f45c1e2a462ac6e7f 100644 (file)
  * limitations under the License.
  */
 
-#include <json-glib/json-glib.h>
 #include "webrtc.h"
 #include "webrtc_private.h"
+#include <json-glib/json-glib.h>
+#include <pulse/proplist.h>
 
 #define DEFAULT_DOT_FILE_NAME_PREFIX   "webrtc"
 
@@ -2208,7 +2209,7 @@ int _apply_stream_info(GstElement *element, const char *stream_type, int stream_
        RET_VAL_IF(!g_object_class_find_property(G_OBJECT_GET_CLASS(G_OBJECT(element)), "stream-properties"),
                WEBRTC_ERROR_INVALID_OPERATION, "could not find 'stream-properties'");
 
-       snprintf(values, sizeof(values) - 1, "props,media.role=%s, media.parent_id=%d", stream_type, stream_index);
+       snprintf(values, sizeof(values) - 1, "props,%s=%s, %s=%d", PA_PROP_MEDIA_ROLE, stream_type, PA_PROP_MEDIA_PARENT_ID, stream_index);
        RET_VAL_IF(!(structure = gst_structure_from_string(values, NULL)),
                WEBRTC_ERROR_INVALID_OPERATION, "failed to gst_structure_from_string(), [%s]", values);