mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-23 06:08:07 +00:00
Fix warnings on msvc compiler
git-svn-id: svn+ssh://svn.savannah.nongnu.org/linphone/trunk@379 3f6dc0c8-ddfe-455d-9043-3cd528dc4637
This commit is contained in:
parent
a6bbbcd1d2
commit
86f108f9d1
6 changed files with 11 additions and 14 deletions
|
|
@ -77,7 +77,7 @@ void mire_draw(MireData *d){
|
|||
|
||||
void mire_process(MSFilter *f){
|
||||
MireData *d=(MireData*)f->data;
|
||||
float elapsed=f->ticker->time-d->starttime;
|
||||
float elapsed=(float)(f->ticker->time-d->starttime);
|
||||
if ((elapsed*d->fps/1000.0)>d->index){
|
||||
mire_draw(d);
|
||||
ms_queue_put(f->outputs[0],dupb(d->pic));
|
||||
|
|
|
|||
|
|
@ -97,6 +97,7 @@ static void resample_process_ms2(MSFilter *obj){
|
|||
short *data_out = (short*)obl->b_wptr;
|
||||
|
||||
int i;
|
||||
spx_uint32_t idx;
|
||||
|
||||
in = (float*) alloca((size_of_input/2)*sizeof(float));
|
||||
out = (float*) alloca((size_of_output/2)*sizeof(float));
|
||||
|
|
@ -111,8 +112,8 @@ static void resample_process_ms2(MSFilter *obj){
|
|||
|
||||
/* ms_message("resampling info: err=%i in_len=%i, out_len=%i", err, in_len, out_len); */
|
||||
|
||||
for (i=0;i<out_len;i++)
|
||||
data_out[i]=floor(.5+out[i]);
|
||||
for (idx=0;idx<out_len;idx++)
|
||||
data_out[idx]=(short)floor(.5+out[idx]);
|
||||
obl->b_wptr=obl->b_wptr+(out_len*2); /* size_of_output; */
|
||||
|
||||
mblk_set_timestamp_info(obl,dt->ts);
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ struct SenderData {
|
|||
char dtmf;
|
||||
char relay_session_id[64];
|
||||
int relay_session_id_size;
|
||||
unsigned int last_rsi_time;
|
||||
uint64_t last_rsi_time;
|
||||
bool_t skip;
|
||||
bool_t mute_mic;
|
||||
};
|
||||
|
|
@ -123,11 +123,7 @@ static int sender_set_relay_session_id(MSFilter *f, void*arg){
|
|||
static uint32_t get_cur_timestamp(MSFilter * f, uint32_t packet_ts)
|
||||
{
|
||||
SenderData *d = (SenderData *) f->data;
|
||||
#if !defined(_WIN32_WCE)
|
||||
uint32_t curts = (f->ticker->time * d->rate) / 1000LL;
|
||||
#else
|
||||
uint32_t curts = (f->ticker->time * d->rate) / ((uint64_t)1000);
|
||||
#endif
|
||||
uint32_t curts = (uint32_t)(f->ticker->time * (d->rate/1000));
|
||||
int diff;
|
||||
int delta = d->rate / 50; /*20 ms at 8000Hz */
|
||||
uint32_t netts;
|
||||
|
|
@ -322,7 +318,7 @@ static void receiver_process(MSFilter * f)
|
|||
if (d->session == NULL)
|
||||
return;
|
||||
|
||||
timestamp = (f->ticker->time * d->rate) / ((uint64_t)1000);
|
||||
timestamp = (uint32_t) (f->ticker->time * (d->rate/1000));
|
||||
while ((m = rtp_session_recvm_with_ts(d->session, timestamp)) != NULL) {
|
||||
mblk_set_timestamp_info(m, rtp_get_timestamp(m));
|
||||
mblk_set_marker_info(m, rtp_get_markbit(m));
|
||||
|
|
|
|||
|
|
@ -190,7 +190,7 @@ static void enc_preprocess(MSFilter *f){
|
|||
if (s->maxbitrate>0){
|
||||
/* convert from network bitrate to codec bitrate:*/
|
||||
/* ((nbr/(50*8)) -20-12-8)*50*8*/
|
||||
int cbr=(((float)s->maxbitrate/(50.0*8))-20-12-8)*50*8;
|
||||
int cbr=(int)( (((float)s->maxbitrate/(50.0*8))-20-12-8)*50*8);
|
||||
if (speex_encoder_ctl(s->state,SPEEX_SET_BITRATE,&cbr)!=0){
|
||||
ms_error("Could not set maxbitrate %i to speex encoder.",s->bitrate);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -118,14 +118,14 @@ static void size_conv_process(MSFilter *f){
|
|||
ms_filter_lock(f);
|
||||
|
||||
if (s->frame_count==-1){
|
||||
s->start_time=f->ticker->time;
|
||||
s->start_time=(float)f->ticker->time;
|
||||
s->frame_count=0;
|
||||
}
|
||||
while((im=ms_queue_get(f->inputs[0]))!=NULL ){
|
||||
putq(&s->rq, im);
|
||||
}
|
||||
|
||||
cur_frame=((f->ticker->time-s->start_time)*s->fps/1000.0);
|
||||
cur_frame=(int)((f->ticker->time-s->start_time)*s->fps/1000.0);
|
||||
if (cur_frame<=s->frame_count && s->fps>=0) {
|
||||
/* too much frame */
|
||||
while(s->rq.q_mcount>1){
|
||||
|
|
|
|||
|
|
@ -110,7 +110,7 @@ static int dec_add_fmtp(MSFilter *f, void *data){
|
|||
for(i=0,j=0;i<max;i+=2,++j){
|
||||
octet[0]=config[i];
|
||||
octet[1]=config[i+1];
|
||||
s->dci[j]=strtol(octet,NULL,16);
|
||||
s->dci[j]=(uint8_t)strtol(octet,NULL,16);
|
||||
}
|
||||
s->dci_size=j;
|
||||
ms_message("Got mpeg4 config string: %s",config);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue