Mercurial > mplayer.hg
comparison libmpcodecs/dec_video.c @ 6566:a48ad140c3af
support the 'align16' codec flag
author | arpi |
---|---|
date | Tue, 25 Jun 2002 22:29:32 +0000 |
parents | 936aa617e829 |
children | 5bf3ed8a17c4 |
comparison
equal
deleted
inserted
replaced
6565:1075fe5fc8c3 | 6566:a48ad140c3af |
---|---|
160 mp_msg(MSGT_DECVIDEO,MSGL_WARN,"Requested video codec family [%s] (vfm=%d) not available (enable it at compile time!)\n", | 160 mp_msg(MSGT_DECVIDEO,MSGL_WARN,"Requested video codec family [%s] (vfm=%d) not available (enable it at compile time!)\n", |
161 sh_video->codec->name, sh_video->codec->driver); | 161 sh_video->codec->name, sh_video->codec->driver); |
162 continue; | 162 continue; |
163 } | 163 } |
164 // it's available, let's try to init! | 164 // it's available, let's try to init! |
165 if(sh_video->codec->flags & CODECS_FLAG_ALIGN16){ | |
166 // align width/height to n*16 | |
167 // FIXME: save orig w/h, and restore if codec init failed! | |
168 if(sh_video->bih){ | |
169 sh_video->disp_w=sh_video->bih->biWidth=(sh_video->bih->biWidth+15)&(~15); | |
170 sh_video->disp_h=sh_video->bih->biHeight=(sh_video->bih->biHeight+15)&(~15); | |
171 } else { | |
172 sh_video->disp_w=(sh_video->disp_w+15)&(~15); | |
173 sh_video->disp_h=(sh_video->disp_h+15)&(~15); | |
174 } | |
175 } | |
176 // init() | |
165 mp_msg(MSGT_DECVIDEO,MSGL_INFO,"Opening video decoder: [%s] %s\n",mpvdec->info->short_name,mpvdec->info->name); | 177 mp_msg(MSGT_DECVIDEO,MSGL_INFO,"Opening video decoder: [%s] %s\n",mpvdec->info->short_name,mpvdec->info->name); |
166 if(!mpvdec->init(sh_video)){ | 178 if(!mpvdec->init(sh_video)){ |
167 mp_msg(MSGT_DECVIDEO,MSGL_INFO,"VDecoder init failed :(\n"); | 179 mp_msg(MSGT_DECVIDEO,MSGL_INFO,"VDecoder init failed :(\n"); |
168 continue; // try next... | 180 continue; // try next... |
169 } | 181 } |