Commit Graph

3200 Commits

Author SHA1 Message Date
Benny Prijono f6bebc36f8 Re #1214: more elaborate tests on vid_dev_test
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3488 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-25 08:23:12 +00:00
Benny Prijono 00ae45add3 libswscale rearrangement (re #1219/ffmpeg codecs): instantiate libswscale converter from the converter manager instead of having to instantiate it manually in all apps
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3487 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-25 08:13:43 +00:00
Nanang Izzuddin 8dbe1a1244 Re #1219: Updated H263 packetizer to just return PJ_EINVAL (instead of triggering assertion) when the supplied bitstream is invalid.
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3486 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-25 07:56:41 +00:00
Sauw Ming 0c668f99c5 Re #1214: Enable pjsua to use SDLmain library if possible.
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3485 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-25 06:57:25 +00:00
Sauw Ming 03ad8906b3 Re #1213:
* Move Mac OS' CFRunLoop object from vid_dev_test inside qt
 * Remove NSApplication object management and auto release pool from vid_dev_test. Temporarily depend on SDLmain library for these.



git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3484 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-24 15:20:05 +00:00
Sauw Ming 1b39a64647 Re #1214: add aviplay in the samples' makefile
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3483 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-24 15:08:54 +00:00
Benny Prijono 587c794c88 Re #1214 (apps): added registrar functionality in pjsua for easier testing
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3477 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-23 06:08:25 +00:00
Nanang Izzuddin 07fe8d35f9 Re #1201: Fixed bad definition of pjsua_vid_set/get_setting() (caused compilation error on GCC).
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3476 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-23 04:43:01 +00:00
Benny Prijono 0ca45f44bd Re 1220: typo in PJ_ALIGN_DATA implementation for gcc
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3473 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-22 10:10:30 +00:00
Nanang Izzuddin 269eec1fc3 Re #1214:
- Added option in pjsua app to select video devices, and modified 'Cp' menu command to also change video codecs priority.



git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3472 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-22 09:50:48 +00:00
Nanang Izzuddin 50fae73e7d Re #1201: Added pjsua API for video devices and codecs management.
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3471 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-22 09:49:23 +00:00
Nanang Izzuddin 63b01ab684 Re #1213:
- Added encoding format conversion (only format ID) in video port.
 - Fixed few bugs in direct show capture device:
   - VIDEOINFOHEADER.AvgTimePerFrame calculation overflow which caused failure in opening capture device.
   - AM_MEDIA_TYPE.formattype validation to avoid bad type casting (of VIDEOINFOHEADER).



git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3470 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-22 09:46:04 +00:00
Nanang Izzuddin ada412638c Re #1219: updated stack aligning mechanism using PJ_ALIGN_DATA (see ticket #1220).
- 


git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3469 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-22 09:43:24 +00:00
Nanang Izzuddin 4415031cee Close #1220:
- Added macro PJ_ALIGN_DATA for aligning data (compiler specific), currently needed by ffmpeg encoder to provide 16-bytes aligned stack for SSE/MMX operation.
 


git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3468 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-22 09:38:49 +00:00
Sauw Ming b93e68808c Re #1213 (video devices):
Modified ios_dev and qt_dev to use pjmedia_vid_dev_stream



git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3467 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-19 05:33:21 +00:00
Benny Prijono 7825c4980a Re #1219: fixed error in Linux/gcc due to unimplemented alignment macro, and remove the assembly implementation
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3466 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-18 09:57:44 +00:00
Benny Prijono 9b61ff5873 Re #1201: replace union media stream in pjsua_call_media with struct, to avoid the conf_slot corrupting the video capturer value
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3465 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-18 09:55:48 +00:00
Nanang Izzuddin bf26db1ec6 Re #1201:
- Initial version of video stream integration into pjsua-lib.
 - Replaced audio info array in pjsua_call_info with media info array.
 - Added video media info into call dump.
 - Fixed assertion caused by pjsua_set_state(NULL) logging after pjlib shutdown.



git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3463 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-18 07:54:50 +00:00
Benny Prijono 135290d24e Re #1215 (framework):
- vstream:
     - allow NULL pool parameter which means vstream will create one
     - Updated remote FPS detection to only be performed if decoder returns frame (however the FPS detection is currently disabled as some endpoints changes fps continuously, causing renderer restart continuously too).
 - codec:
     - Updated video codec info to have RTP packetization support flag, also update endpoint in generating SDP to only include codecs whose RTP packetization support.
     - Added dynamic payload types for video codecs.
     - (minor) separate video PT into separate enum in pjmedia-codec/types.h
 - H264 initial experiment.
generated frames (for libx264 sake).
 - Replaced PJ_EUNKNOWN in some places with the appropriate error code.



git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3461 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-17 11:33:34 +00:00
Benny Prijono f35f842c71 Re #1214: work on simpleua:
- protect with #ifdef PJMEDIA_HAS_VIDEO etc.
 - fix the format setting to get the format from the correct port


git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3460 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-17 11:27:37 +00:00
Benny Prijono 349037b25d Re #1213 (video devices):
- fixed devices to correctly increment the frame timestamp
 - minor fix in video port to set default "active" value to 1 in the param


git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3459 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-17 11:25:19 +00:00
Benny Prijono 0bc99a9ca3 Modifications in PJSUA-LIB to support multiple media streams (multiple audio and/or video) and dynamic creation of media transports. This closed #1185 and closed #1201.
1185: Dynamic creation of media transports
============================================
Done:
 - media transports are created on demand now

Todo:
 - media transport creation is still blocking


1201: Video support in PJSUA-LIB
===================================
Done:
 - call now supports N media (N audio and M video)
 - number of audio/video streams is configurable per acc
 - extra audio stream info in pjsua_call_info to support multiple audio streams
in one call
 - video subsys and ffmpeg initialization in PJSUA-LIB
 - ability to offer and create video SDP answer
 - "dq" for more than 1 audio streams
 - introducing pjsua_state and pjsua_get_state()

API change:
 - on_stream_created() and on_stream_destroyed() callbacks: changed session to
stream

Todo:
 - many others features are disabled, just search for DISABLED_FOR_TICKET_1185
macro (these have also been added to ticket #1193 (Issues & Todos)). Notable
missing features are:
      - creation of duplicate SDP m= lines for optional SRTP
      - mm.. that's it?
 - whole lot of testings

pjsua:
===============
 - Added --extra-audio and --video options. Specify these more than once and
each time an extra audio/video streams will be added. :)



git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3457 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-17 04:34:43 +00:00
Benny Prijono 854ec1a682 Re #1208 (misc): added PJMEDIA_HAS_VIDEO macro as the top level macro to disable video features
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3451 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-15 11:29:53 +00:00
Benny Prijono 867280b9eb Re #1186 (SDP works); added few more APIs for SDP generation:
- pjmedia_endpt_create_base_sdp(): create blank SDP
 - pjmedia_endpt_create_audio_sdp(): create m=audio SDP media
 - pjmedia_endpt_create_video_sdp(): create m=video SDP media


git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3450 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-15 11:28:24 +00:00
Benny Prijono 51a4a2924a Re #1208 (misc): bug in frame_size calculation in PJMEDIA_FSZ() causing results to be truncated
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3449 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-15 11:25:00 +00:00
Benny Prijono 8e0fa3cff9 Re #1208 (misc): bug in resample_port, the port info is accessed before it is initialized
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3448 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-15 11:23:48 +00:00
Benny Prijono 6c7e95ee59 Re #1182: renamed pjmedia_vid_stream to pjmedia_vid_dev_stream due to conflict with "the real" vid_stream
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3447 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-15 11:22:04 +00:00
Benny Prijono fe74aec894 Fixed #1207: Deprecation of pjmedia_session:
- add new APIs in stream so that app can use this directly instead of via session
 - moved some APIs from session to stream


git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3446 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-15 11:20:35 +00:00
Benny Prijono 1641953c2d Re #1182: added the video stream to pjmedia Makefile
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3445 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-15 11:12:53 +00:00
Nanang Izzuddin 678b2f82e0 Re #1182:
- Added remote frame-rate detection in to video stream.
 - Fixed bitrate settings in ffmpeg codec.
 - Fixed SDL dev to update internal SDL info when format changed.
 - Minor fixes/updates, e.g:
   - added cleanup steps, fixed logs, etc, in sample app simpleua.c and vid_streamutil.c
   - fixed/added docs of the new APIs in the jitter buffer.




git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3435 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-02 08:37:31 +00:00
Nanang Izzuddin 9861070228 Re #1182:
- Fixed ffmpeg codec: decoding buffer size check (should not use assertion), reset output bit_info before decoding, removed unused code of auto resize when decoder output size changed.
 - Fixed bug in sdl_factory_default_param() of sdl_dev.c in device direction check.
 - Fixed compile errors sample app vid_streamutil.c of bad local variable definiton.
 - Updated sample app vid_streamutil.c default renderer size to 640 x 480.



git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3432 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-01 17:40:17 +00:00
Sauw Ming 4a20bc808a Re #1182:
* support for format modification after creating video port (currently for renderer with active role only).
 * support for format modification after opening SDL renderer.



git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3431 74dad513-b988-da41-8d7b-12977e46ad98
2011-03-01 15:55:34 +00:00
Nanang Izzuddin 235e1b4fa6 Re #1182:
- Renamed vstreamutil.c to vid_steamutil.c just for filename format consistency reason.
 - Updated sample app simpleua.c and vid_streamutil.c to sync with updated API, e.g: strip session usage, two media ports exported video streams for each dir.
 - Added vid_streamutil.c capability to be able to stream video file (involving transcoding when video codec used in the file different to the video stream codec), also updated AVI player and ffmpeg codecs to be able to read and decode XVID/MPEG4 codec.
 - Fixed bug wrong media type check in stream.c and vid_stream.c in creating stream info from SDP.
 - Minor update: docs, logs, app samples makefiles.



git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3425 74dad513-b988-da41-8d7b-12977e46ad98
2011-02-28 18:59:47 +00:00
Nanang Izzuddin a9c1cf45be Re #1182:
- Added video stream interface in vid_stream.h, the video stream will be able to handle different video formats in encoding and decoding direction.
 - Renamed video device stream class identifiers from 'pjmedia_vid_stream*' to 'pjmedia_vid_dev_stream*' as 'pjmedia_vid_stream' is used by video stream interface.
 - Added ffmpeg video capability to be able to parse SDP format param for H263 and also decide video format for encoding direction based on remote preference and local format-capability setting.
 - Added some new APIs in jitter buffer for handling video stream: pjmedia_jbuf_put_frame3(), pjmedia_jbuf_get_frame3(), pjmedia_jbuf_peek_frame(), and pjmedia_jbuf_remove_frame().
 - Moved pjmedia_stream_info_from_sdp() from session to stream




git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3420 74dad513-b988-da41-8d7b-12977e46ad98
2011-02-24 07:47:55 +00:00
Nanang Izzuddin c85a00d1ca Re #1186:
- Added API pjmedia_sdp_conn_cmp() to compare SDP connection.
 - Added internal API pjmedia_stream_info_parse_fmtp() to parse SDP format parameter of specified payload as a helper function for generating stream info from SDP.
 - Modified pjmedia_endpt_create_sdp() to be able to generate SDP media line for video.




git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3419 74dad513-b988-da41-8d7b-12977e46ad98
2011-02-24 07:16:31 +00:00
Nanang Izzuddin ecaaec06e0 Re #1182: Reverted back video part in stream.h/c
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3418 74dad513-b988-da41-8d7b-12977e46ad98
2011-02-24 05:14:34 +00:00
Sauw Ming 8e799128a1 Re #1184: Adding pjmedia_clock_src for the purpose of audio and video synchronization and also to provide synchronization mechanism between two medias in general.
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3402 74dad513-b988-da41-8d7b-12977e46ad98
2010-12-30 16:31:16 +00:00
Sauw Ming b1b17d221e Fixed #1184:
* Move the AVI playback from pjmedia-test to new aviplay.c sample application
 * Take the input file from cmdline
 * Synchronize audio and video
 * Remove all codecs related hardcodes from the file 

Re #1193: (no. 6: duplicate fps and frame_rate in pjmedia_format and pjmedia_vid_param)
 * Remove the frame_rate in pjmedia_vid_param
 * Use pjmedia_format's fps in videoport, sdl_dev, and colorbar_dev
 * Prevent overflow in ptime calculation from frame_rate



git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3401 74dad513-b988-da41-8d7b-12977e46ad98
2010-12-20 11:02:48 +00:00
Sauw Ming ab494302d8 Re #1183:
* Add PJMEDA_VID_DEV_CAP_OUTPUT_WINDOW capability to ios_dev to allow application to provide their own window for the renderer to display the video.
 * Perform image setting function in the main thread.
 


git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3399 74dad513-b988-da41-8d7b-12977e46ad98
2010-12-17 13:17:23 +00:00
Sauw Ming 6e6c215f70 Fixed #1183
* QT capture device for Mac
 * iOS device for iOS (capture device only works for iOS 4.0 or above)
 * Add NSAutoReleasePool for sdl_dev (Mac)
 * Add NSAutoReleasePool for vid_dev_test (Mac)
 * build system for compilation of Obj-C files (.m)



git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3395 74dad513-b988-da41-8d7b-12977e46ad98
2010-12-14 13:03:10 +00:00
Nanang Izzuddin e43ee729d4 Re #1176: fixed build config for MSVC2005
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3394 74dad513-b988-da41-8d7b-12977e46ad98
2010-12-10 20:55:13 +00:00
Benny Prijono 69b1f82cae Re #1176: fixed link error in GNU build system
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3393 74dad513-b988-da41-8d7b-12977e46ad98
2010-12-10 11:33:01 +00:00
Benny Prijono c45d951901 Migration of current video works from private repository to this repository. This closed #1176
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3392 74dad513-b988-da41-8d7b-12977e46ad98
2010-12-10 11:04:30 +00:00
Benny Prijono 7f5aa6f127 Created 2.0-dev branch for 2.0 development.
git-svn-id: https://svn.pjsip.org/repos/pjproject/branches/projects/2.0-dev@3391 74dad513-b988-da41-8d7b-12977e46ad98
2010-12-07 10:52:53 +00:00
Benny Prijono 4034240ebd Changed version to 1.8.10-trunk
git-svn-id: https://svn.pjsip.org/repos/pjproject/trunk@3390 74dad513-b988-da41-8d7b-12977e46ad98
2010-12-07 08:50:57 +00:00
Benny Prijono 3913b7e471 Changed version to 1.8.10
git-svn-id: https://svn.pjsip.org/repos/pjproject/trunk@3388 74dad513-b988-da41-8d7b-12977e46ad98
2010-12-07 06:26:30 +00:00
Benny Prijono ae6f32d32e Fixed #1160: Option to bypass RTP payload type verification in the stream (thanks Johan Lantz for the suggestion)
git-svn-id: https://svn.pjsip.org/repos/pjproject/trunk@3387 74dad513-b988-da41-8d7b-12977e46ad98
2010-12-06 04:25:44 +00:00
Sauw Ming 5321ca7759 Misc (re #1151): Fixed crash in coreaudio_dev when there is no call during an interruption.
git-svn-id: https://svn.pjsip.org/repos/pjproject/trunk@3386 74dad513-b988-da41-8d7b-12977e46ad98
2010-12-05 14:03:31 +00:00
Benny Prijono 9d33c95716 Misc (re #1151): respond incoming re-INVITE with 491 instead of 500 if we are waiting for response for our outgoing re-INVITE. If we are currently processing another incoming re-INVITE, then respond with 500, as it is now
git-svn-id: https://svn.pjsip.org/repos/pjproject/trunk@3385 74dad513-b988-da41-8d7b-12977e46ad98
2010-12-02 11:21:01 +00:00
Nanang Izzuddin fe30a53008 Re #1165: fixed SRTP transport to not update the SRTP activation flag, i.e: bypass_srtp, in transport_encode_sdp(), as it shouldn't change the media session states.
git-svn-id: https://svn.pjsip.org/repos/pjproject/trunk@3384 74dad513-b988-da41-8d7b-12977e46ad98
2010-12-02 10:56:27 +00:00