Changeset 3972


Ignore:
Timestamp:
Mar 9, 2012 3:29:05 AM (12 years ago)
Author:
nanang
Message:

Misc (re #1446): Updated ffmpeg video codecs default params:

  • decoder fps to be 1.5x faster than encoder's, to encounter accumulated frames in jbuf when decoder clock gets short pauses in video setup (e.g: renderer creation, format change)
  • separate size & fps for H.264 and H.263
File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjmedia/src/pjmedia-codec/ffmpeg_codecs.c

    r3922 r3972  
    212212                                                     to copy this codec desc 
    213213                                                     from its base format   */ 
     214    pjmedia_rect_size            size; 
     215    pjmedia_ratio                fps; 
    214216    pj_uint32_t                  avg_bps; 
    215217    pj_uint32_t                  max_bps; 
     
    256258        {PJMEDIA_FORMAT_H264, PJMEDIA_RTP_PT_H264, {"H264",4}, 
    257259         {"Constrained Baseline (level=30, pack=1)", 39}}, 
    258         0,      256000,    512000, 
     260        0, 
     261        {720, 480},     {30, 1},        256000, 512000, 
    259262        &h264_packetize, &h264_unpacketize, &h264_preopen, &h264_postopen, 
    260263        &pjmedia_vid_codec_h264_match_sdp, 
     
    268271    { 
    269272        {PJMEDIA_FORMAT_H263P, PJMEDIA_RTP_PT_H263P, {"H263-1998",9}}, 
    270         PJMEDIA_FORMAT_H263,    256000,    512000, 
     273        PJMEDIA_FORMAT_H263, 
     274        {352, 288},     {30000, 1001},  256000, 512000, 
    271275        &h263_packetize, &h263_unpacketize, &h263_preopen, NULL, NULL, 
    272276        {2, { {{"CIF",3},   {"1",1}},  
     
    914918    /* Encoded format */ 
    915919    pjmedia_format_init_video(&attr->enc_fmt, desc->info.fmt_id, 
    916                               720, 480, 30000, 1001); 
     920                              desc->size.w, desc->size.h, 
     921                              desc->fps.num, desc->fps.denum); 
    917922 
    918923    /* Decoded format */ 
    919924    pjmedia_format_init_video(&attr->dec_fmt, desc->info.dec_fmt_id[0], 
    920                               //352, 288, 30000, 1001); 
    921                               720, 576, 30000, 1001); 
     925                              desc->size.w, desc->size.h, 
     926                              desc->fps.num*3/2, desc->fps.denum); 
    922927 
    923928    /* Decoding fmtp */ 
Note: See TracChangeset for help on using the changeset viewer.