summaryrefslogtreecommitdiff
path: root/pjmedia/src/test
diff options
context:
space:
mode:
authorBenny Prijono <bennylp@teluu.com>2012-03-22 09:56:52 +0000
committerBenny Prijono <bennylp@teluu.com>2012-03-22 09:56:52 +0000
commited4644930dd8a74bcf4d4a89298a907643bd5d30 (patch)
treed2244ba52cc6fe2eb3dff9732a39b9b11eea825f /pjmedia/src/test
parent5bef8e17b3b0ffcfa59ad195787c956903b81978 (diff)
Re: #1463 (Third party media support). Tnitial work and it works, tested on Linux. Details:
* add PJSUA_MEDIA_HAS_PJMEDIA macro * move pjmedia specific implementation in pjsua_media.c and pjsua_call.c into pjsua_aud.c * add pjsip-apps/src/third_party_media sample containing: - alt_pjsua_aud.c - alt_pjsua_vid.c * moved pjmedia_vid_stream_info_from_sdp() into pjmedia/vid_stream_info.c * moved pjmedia_stream_info_from_sdp() into pjmedia/stream_info.c * misc: fixed mips_test.c if codecs are disabled git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@3982 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjmedia/src/test')
-rw-r--r--pjmedia/src/test/mips_test.c18
1 files changed, 17 insertions, 1 deletions
diff --git a/pjmedia/src/test/mips_test.c b/pjmedia/src/test/mips_test.c
index 977fe9a0..4d5c94cb 100644
--- a/pjmedia/src/test/mips_test.c
+++ b/pjmedia/src/test/mips_test.c
@@ -793,6 +793,7 @@ static pjmedia_port* codec_encode_decode( pj_pool_t *pool,
return &cp->base;
}
+#if PJMEDIA_HAS_G711_CODEC
/* G.711 benchmark */
static pjmedia_port* g711_encode_decode( pj_pool_t *pool,
unsigned clock_rate,
@@ -806,8 +807,10 @@ static pjmedia_port* g711_encode_decode( pj_pool_t *pool,
clock_rate, channel_count,
samples_per_frame, flags, te);
}
+#endif
/* GSM benchmark */
+#if PJMEDIA_HAS_GSM_CODEC
static pjmedia_port* gsm_encode_decode( pj_pool_t *pool,
unsigned clock_rate,
unsigned channel_count,
@@ -820,7 +823,9 @@ static pjmedia_port* gsm_encode_decode( pj_pool_t *pool,
clock_rate, channel_count,
samples_per_frame, flags, te);
}
+#endif
+#if PJMEDIA_HAS_ILBC_CODEC
static pj_status_t ilbc_init(pjmedia_endpt *endpt)
{
return pjmedia_codec_ilbc_init(endpt, 20);
@@ -839,7 +844,9 @@ static pjmedia_port* ilbc_encode_decode( pj_pool_t *pool,
&pjmedia_codec_ilbc_deinit, clock_rate,
channel_count, samples_per_frame, flags, te);
}
+#endif
+#if PJMEDIA_HAS_SPEEX_CODEC
/* Speex narrowband benchmark */
static pjmedia_port* speex8_encode_decode(pj_pool_t *pool,
unsigned clock_rate,
@@ -869,7 +876,9 @@ static pjmedia_port* speex16_encode_decode(pj_pool_t *pool,
clock_rate, channel_count,
samples_per_frame, flags, te);
}
+#endif
+#if PJMEDIA_HAS_G722_CODEC
/* G.722 benchmark benchmark */
static pjmedia_port* g722_encode_decode(pj_pool_t *pool,
unsigned clock_rate,
@@ -883,6 +892,7 @@ static pjmedia_port* g722_encode_decode(pj_pool_t *pool,
clock_rate, channel_count,
samples_per_frame, flags, te);
}
+#endif
#if PJMEDIA_HAS_G7221_CODEC
/* G.722.1 benchmark benchmark */
@@ -1796,6 +1806,7 @@ static pjmedia_port* create_stream( pj_pool_t *pool,
return port;
}
+#if PJMEDIA_HAS_G711_CODEC
/* G.711 stream, no SRTP */
static pjmedia_port* create_stream_pcmu( pj_pool_t *pool,
unsigned clock_rate,
@@ -1870,7 +1881,9 @@ static pjmedia_port* create_stream_pcmu_srtp80_with_auth(pj_pool_t *pool,
clock_rate, channel_count,
samples_per_frame, flags, te);
}
+#endif
+#if PJMEDIA_HAS_GSM_CODEC
/* GSM stream */
static pjmedia_port* create_stream_gsm( pj_pool_t *pool,
unsigned clock_rate,
@@ -1945,7 +1958,9 @@ static pjmedia_port* create_stream_gsm_srtp80_with_auth(pj_pool_t *pool,
clock_rate, channel_count,
samples_per_frame, flags, te);
}
+#endif
+#if PJMEDIA_HAS_G722_CODEC
/* G722 stream */
static pjmedia_port* create_stream_g722( pj_pool_t *pool,
unsigned clock_rate,
@@ -1960,9 +1975,10 @@ static pjmedia_port* create_stream_g722( pj_pool_t *pool,
clock_rate, channel_count,
samples_per_frame, flags, te);
}
+#endif
-/* G722.1 stream */
#if PJMEDIA_HAS_G7221_CODEC
+/* G722.1 stream */
static pjmedia_port* create_stream_g7221( pj_pool_t *pool,
unsigned clock_rate,
unsigned channel_count,