Вниз
Скачать: CL | DM;

Корректное снятие видео при копировании образа экрана   Найти похожие ветки 

 
dmitry_12_08_74   (2008-03-11 14:26) [0]

Если во время копирования образа экрана запущен Media Palyer во время показа им видео, на снимке образа экрана вместо кадра из фильма останется чёрное пустое место. Как корректно скопировать кадр?

Сейчас копирую образ экрана с помощью процедуры из библиотеки jcl_&_jvcl, модуль JclGraphics:

procedure ScreenShot(bm: TBitmap; Left, Top, Width, Height: Integer; Window: THandle); overload;
var
 WinDC: HDC;
 Pal: TMaxLogPalette;
begin
 bm.Width := Width;
 bm.Height := Height;

 // Get the HDC of the window...
 WinDC := GetDC(Window);
 if WinDC = 0 then
   raise EJclGraphicsError.CreateRes(@RsNoDeviceContextForWindow);

 // Palette-device?
 if (GetDeviceCaps(WinDC, RASTERCAPS) and RC_PALETTE) = RC_PALETTE then
 begin
   FillChar(Pal, SizeOf(TMaxLogPalette), #0);  // fill the structure with zeros
   Pal.palVersion := $300;                     // fill in the palette version

   // grab the system palette entries...
   Pal.palNumEntries := GetSystemPaletteEntries(WinDC, 0, 256, Pal.palPalEntry);
   if Pal.PalNumEntries <> 0 then
     bm.Palette := CreatePalette(PLogPalette(@Pal)^);
 end;

 // copy from the screen to our bitmap...
 BitBlt(bm.Canvas.Handle, 0, 0, Width, Height, WinDC, Left, Top, SRCCOPY);

 ReleaseDC(Window, WinDC);        // finally, relase the DC of the window
end;


 
DVM ©   (2008-03-11 14:40) [1]

там оверлей используется поэтому и не получается



Страницы: 1 вся ветка

Скачать: CL | DM;



Память: 0.45 MB
Время: 0.053 c
2-1274433156
ixen
2010-05-21 13:12
2010.08.27
Как узнать путь к bat файлу запускающий exe


2-1271231298
Анна
2010-04-14 11:48
2010.08.27
sp_help доступ к данным второго recordset


2-1271319504
Б
2010-04-15 12:18
2010.08.27
Не срабатывает SetWaitableTimer.


6-1217494891
laao
2008-07-31 13:01
2010.08.27
Как получить детали отклоненного запроса - IdHTTPServer+OpenSSL ?


15-1271140789
TRSteep
2010-04-13 10:39
2010.08.27
Net Framework 3.5 зависает при установке




   Наверх