VOD点播系统中图象显示问题,在线等待(300分)

  • 主题发起人 主题发起人 confidentbb
  • 开始时间 开始时间
C

confidentbb

Unregistered / Unconfirmed
GUEST, unregistred user!
VOD点播系统中图象显示控制在本机上和电视上
我计划采用mciSendCommand();
各位高手请指导,
相关知识也行,有效的可分分数,
各位高手请多帮忙,
分数可再加,只要有用。
 
const FMPI_VID_TV = $041b;
const SET_VGA = 2;
const SET_TV = 1;

FMPSet(FStreamID, FMPI_VID_TV, SET_VGA );
//输出到显示器
FMPSet(FStreamID, FMPI_VID_TV, SET_TV );
//输出到电视
 
to houling
可不可以详细一点,
谢谢 你是不是用到 dvd 的SDK包了。问一下FMPUpdateVGAMode()怎么用?
可不可以只用mci呢,
谢谢。
 
const MCI_FMPCOMMAND = $00100000;
const MCI_FMPFLAG = $00200000;
consg MCI_FMPVALUE = $00400000;

type MCI_DGV_FMP_PARMS=record
dwCallback:DWORD
dwReturn:DWORD
dwCommand:DWORD
dwFlag:DWORD
dwValue:DWORD
rc:RECT
end;



//1.Open device
var
mciOpen : MCI_DGV_OPEN_PARMS;
dwResult : DWORD;
wDeviceID : WORD;// MCI device ID
begin

mciOpen.lpstrDeviceType := 'reelmagic'; // Realmagic驱动已安装
mciOpen.lpstrElementName = 'D:/song/music01.dat';
dwResult = mciSendCommand(0,MCI_OPEN, MCI_OPEN_ELEMENT,
LongInt(@mciOpen)); //打开文件
if dwResult =0 then

wDeviceID := mciOpen.wDeviceID; //save device ID to be used on all other commands
end;

//2.Video out VGA
var
mcifmp:MCI_DGV_FMP_PARMS;
dwFlags:DWORD;
begin

mcifmp.dwValue= 2; //chapter
mcifmp.dwCommand=$041b;
dwFlags = MCI_FMPVALUE or MCI_FMPFLAG or MCI_FMPCOMMAND;
mciSendCommand(wDeviceID,MCI_FMP,dwFlags,
longInt(@mcifmp));
end;




// (3) Close device

var
mciClose:MCI_GENERIC_PARMS;
begin


mciSendCommand(wDeviceID,MCI_CLOSE,0,
Longint(@mciClose));
end;

//do
ne.

 
TO houling,你的测试过没,好象不行也。
我的代码如下。帮忙看一下,该如何修改,只有声音没图象。谢谢
var
openParams: MCI_OPEN_PARMS;
playParams: MCI_PLAY_PARMS;
// MCI_DGV_PLAY_PARMS
hStream: Byte;

procedure TForm1.BitBtn1Click(Sender: TObject);
var
animWindow: MCI_ANIM_WINDOW_PARMS;
begin

if OpenDialog1.Execute then

begin

openParams.lpstrDeviceType :='REELMagic';
openParams.lpstrElementName := PChar(OpenDialog1.FileName);
openParams.dwCallback := Self.Handle;
if mciSendCommand(0, MCI_OPEN,
MCI_OPEN_ELEMENT or MCI_OPEN_TYPE,DWORD(@openParams)) <> 0 then

begin

Application.MessageBox('MCI设备初始化失败!','警告:',MB_OK or MB_ICONWARNING);
Exit;
end;

animWindow .Wnd :=Self .Handle
mciSendCommand(openParams.wDeviceID,MCI_WINDOW,MCI_NOTIFY or MCI_ANIM_WINDOW_HWND ,DWORD(@animWindow));
mciSendCommand(openParams.wDeviceID, MCI_PLAY, 0, DWORD(@playParams));
end;

end;


 
http://www.delphibbs.com/delphibbs/dispq.asp?lid=886191
http://www.delphibbs.com/delphibbs/dispq.asp?lid=1181350
 
TO houling
有个问题,调试不通,谢谢,再看一下
//2.Video out VGA
var
mcifmp:MCI_DGV_FMP_PARMS;
dwFlags:DWORD;
begin

mcifmp.dwValue= 2; //chapter
mcifmp.dwCommand=$041b;
dwFlags = MCI_FMPVALUE or MCI_FMPFLAG or MCI_FMPCOMMAND;
mciSendCommand(wDeviceID,MCI_FMP,dwFlags,
longInt(@mcifmp));
end;

中提示
mciSendCommand(wDeviceID,MCI_FMP,dwFlags,
longInt(@mcifmp));
中MCI_FMP没定义,是不是错了,麻烦一下
谢谢。
 
mciSendCommand(wDeviceID,MCI_FMP,dwFlags,
longInt(@mcifmp));
中MCI_FMP没定义,是不是错了,麻烦一下
谢谢。
 
多人接受答案了。
 

Similar threads

S
回复
0
查看
3K
SUNSTONE的Delphi笔记
S
S
回复
0
查看
2K
SUNSTONE的Delphi笔记
S
D
回复
0
查看
2K
DelphiTeacher的专栏
D
D
回复
0
查看
2K
DelphiTeacher的专栏
D
后退
顶部