这个程序里几个参数是什么意思解决办法
发布时间:2011-06-27 19:26:42 文章来源:www.iduyao.cn 采编人员:星星草
这个程序里几个参数是什么意思
#include <stdio.h>
#include <conio.h>
#include <sys/stat.h>
#include <ddraw.h>
#pragma comment(lib,"ddraw.lib")
unsigned char *y;
unsigned char *u;
unsigned char *v;
bool testsize(int w, int h, int s, int *pw, int *ph);
int main(int argc, char *argv[])
{
HRESULT hr;
LPDIRECTDRAW lpDD;
DDSURFACEDESC ddsd;
LPDIRECTDRAWSURFACE lpPrimary;
LPDIRECTDRAWSURFACE lpOverlay;
RECT rcSrc;
FILE *fd;
int i, j, f;
char name[256];
unsigned char *py, *pu, *pv;
unsigned int *dst;
int ffirst, fcount, ms_per_frame;
int width, height, size;
int width2, height2, size2;
int t1, t2;
char c;
bool done, wait;
if (argc != 4 && argc != 6 && argc != 7)
{
fprintf(stderr, "vidplay template first count [width height [ms_per_frame]]");
return -1;
}
sscanf(argv[2], "%d", &ffirst);
sscanf(argv[3], "%d", &fcount);
if (argc == 7)
{
sscanf(argv[6], "%d", &ms_per_frame);
}
else
{
ms_per_frame = 33;
}
if (argc >= 6)
{
sscanf(argv[4], "%d", &width);
sscanf(argv[5], "%d", &height);
}
else
{
struct _stat st;
sprintf(name, argv[1], ffirst);
if (_stat(name, &st) != 0)
return -1;
size = st.st_size;
if (!(testsize( 176, 144, size, &width, &height)
|| testsize( 352, 240, size, &width, &height)
|| testsize( 352, 480, size, &width, &height)
|| testsize( 704, 480, size, &width, &height)
|| testsize( 720, 480, size, &width, &height)
|| testsize( 352, 288, size, &width, &height)
|| testsize( 352, 576, size, &width, &height)
|| testsize( 704, 576, size, &width, &height)
|| testsize( 720, 576, size, &width, &height)
|| testsize( 8, 8, size, &width, &height)
|| testsize( 16, 16, size, &width, &height)
|| testsize( 32, 32, size, &width, &height)
|| testsize( 64, 64, size, &width, &height)
|| testsize( 128, 128, size, &width, &height)
|| testsize( 256, 256, size, &width, &height)
友情提示:
信息收集于互联网,如果您发现错误或造成侵权,请及时通知本站更正或删除,具体联系方式见页面底部联系我们,谢谢。
其他相似内容:
-
DSHOW push
推模式,ConnectDirect 的,为什么我一直反回错误
下级级用的是HAALI的一个东西,用CMemStream拉模式的时候是可以连接的
...
-
ffmpeg编码后视频速度不正确,质量也不好,求助,求助,求助,求助啊
对采集到得摄像头图像进行编码保存,发现得到的视频质量不好,而且速度不...
-
请问怎么在live555中接收jpeg
请问,我现在想接收一个服务器发送的jpeg 不知道怎么用live555做一个客户端, 接收它并显示。
请问应...
-
XP SP3 YUV420 的fiter依赖 在线等答案……
链接时媒体类型为WMMEDIASUBTYPE_I420
有的XP可以播放出来
有的就不行,请问不能播放...
-
如何获取通过麦克风来获取当前说话的音量?
使用Wave系统API采集音频输入的数据,当数据缓存区满了后,收到消息取得数据后,如何根据这里...
-
RFC3984 有没有完整的中文版本呢?
搜了几个 都是一半英文一半中文的。哎 郁闷!
------解决方案--------------------
英文的凑合...
-
介绍一个学习directshow和com、atl技术的网站
有一个学习directshow和com、atl技术的网站,还可以下视频教程,共享给大家: http://www...
-
攻击帖:jrtplib、live555是个垃圾,刚开始搞流媒体就用这玩意就是找s
不解释~
来丢我砖头吧~~
我分太多了用不完~ 支持的散分~~~
...
-
50分,寻找《Visual C++音频/视频处理技术及工程实践》的随书光盘?
急于使用其中的几个例程。若哪位好心人能够提供,非常感谢!!我的QQ:52...
-
h264的高宽比怎么获取?
我看标准里面只有样点的高宽比啊。
还有,bit rate可以读出来吗?
------解决方案--------------------
是要...