b2科目四模拟试题多少题驾考考爆了怎么补救
b2科目四模拟试题多少题 驾考考爆了怎么补救

bitblt_bitblt stretchblt_bitblt中源设备的像素(5)

电脑杂谈  发布时间:2017-01-20 00:03:23  来源:网络整理

---- 3. 在Visual C++5.0中按Ctrl_W进入MFC ClassWizard,选择类名称为CMainFrame,ObjectIDs: ID_VIEW_BITMAP,Messa

From: Toni Martir <techni-web@pala.com>

To: Earl F. Glynn <EarlGlynn@att.net>

Subject: RE: How to extract a bitmap from an avi file

Date: Wednesday, January 20, 1999 4:32 AM

I have one example

pavi:PIFile;

pavis:PIStream;

pavisound:PIStream;

ob:PGetFrame;

pbmi:PBitmapInfoHeader;

Punter:PByte;

han,i:integer;

Desti:TCanvas;

microsperframe:integer;

principio,fin:integer;

if 0<>IFIleOpen(pavi,Pchar(FFilename),OF_READ,nil) then

Raise Exception.Create('No se pudo abrir el archivo');

Desti:=Canvas;

if IERR_NODATA=IFILEGetStream(pavi,pavis,streamtypeVIDEO,0) then

Raise Exception.Create('Error no hay pista de audio');

principio:=IStreamStart(pavis);

fin:=IStreamENd(pavis);

ShowMessage(IntToStr(IStreamLength(pavis)));

ob:=IStreamGetFrameOpen(pavis,nil);

if nil=ob then

Raise Exception.Create('Error en Frameopen');

han:=DrawDIBOpen;

try

microsperframe:=Trunc(1000000/(info.dwRate/info.dwScale));

DrawDIBStart(han,microsperframe);

DrawDIBStart(han,microsperframe);

i:=0;

if 0<>IStreamBeginStreaming(pavis,principio,fin,1000) then

Raise Exception.Create('Error n IBegin');

pbmi:=IStreamGetFrame(ob,i);

While pbmi<>Nil do

begin

Punter:=Pointer(Integer(pbmi)+pbmi^.biSize);

DRawDIBBegin(han,desti.handle,0,0,pbmi,pbmi^.biWidth,pbmi^.biheight,DDF_ANIM

ATE);

DrawDIBRealize(han,desti.handle,false);

DrawDIBDraw(han,desti.handle,0,0,pbmi^.biWidth,pbmi^.biheight,pbmi,Punter,0,


本文来自电脑杂谈,转载请注明本文网址:
http://www.pc-fly.com/a/jisuanjixue/article-27468-5.html

相关阅读
    发表评论  请自觉遵守互联网相关的政策法规,严禁发布、暴力、反动的言论

    热点图片
    拼命载入中...