How to improve the speed of the screen?

zhaozj2021-02-08  311

Author:

Seaky Posted:

1999-10-14 23:29:18

Return to "VC Forum"

Return quickly

I use the following method to intercept the screen, but I found that the entire 800x600x24 screen requires about 200ms, is there a faster way? The sooner the better! HDC hScrDC, hMemDC; HBITMAP hBitmap, hOldBitmap; hScrDC = CreateDC ( "DISPLAY", NULL, NULL, NULL); hMemDC = CreateCompatibleDC (hScrDC); hBitmap = CreateCompatibleBitmap (hScrDC, nWidth, nHeight); hOldBitmap = (HBITMAP) SelectObject ( HMEMDC, HBitmap; Bitblt (HMEMDC, 0, 0, NWidth, NHEIGHT, HSCRDC, NX, NY, SRCCPY); HbitMap = (Hbitmap) SelectObject (HMEMDC, Holdbitmap); Thank you.

Supplement date: 1999-10-14 23:32:06

SmallTalk 1999-10-02 23:30:53 replace Bitblt to other functions, such as Stretchblt or StretchDibits. Maybe it will be much faster. Seaky (555079468) 1999-10-05 08:39:29 I have tried the effect of the Stretchblt function and the Bitblt function, I think StretchDibits is not too bad! I think it should be changed ... I am using DirectDraw, and I have got a pointer to the main surface but I don't know what to do. Whether this is ... LPDIRECTDRAWSURFACE lpDDSPrimary; HDC lphDC = NULL; HBITMAP hBitmap; lpDDSPrimary-> GetDC (& lphDC); hBitmap = CreateCompatibleBitmap (lphDC, nWidth, nHeight); ... Seaky (555079468) 1999-10-08 22: 17:11 How do I know how to get a pointer to the main surface. Use the LOCK to get the current frame, then obtain the data pointer "SCR" of the current screen. However, I found this speed is still very fast! I need to catch a 800x600x24 screen only 50ms around 50ms! DirectDraw's high-hand door, where are you? Tengel 1999-10-09 11:21:37 After you use Lock to lock, you must be very slow, you can't use the REP MOVS like compilation, I am not too clear. Seaky 1999. -10-09 23:11:17 is a good suggestion! But I am not clear in this respect.

Supplement date: 1999-10-15 23:12:31

Seaky (555079468) 1999-10-10 23:02:57 Do you have a method recommended by the Tengel? LWM 1999-10-11 16:33:09 VC STK Sample WinCap Speed ​​quickly Kasper (555081595) 1999-10-11 21:52:27 The method used by WinCap is exactly the same as Seaky's approach.

Supplement date: 1999-10-16 11:55:48

Seaky (555079468) 1999-10-11 23:11:05 Thank you LWM, Kasper, Tengel, Smalltalk! Is there any other suggestion? A friend suggests that I use DirectShow, because DirectShow is fast than DD, but I am not familiar with this, is there any one know? No matter what method used, as long as I meet my requirements, I admire him (she)! HWZHANG (555050397) 1999-10-12 09:22:34 If you don't care about the quality of the graphics, you can make a draw, such as every four pixels, a lot of speed, the graphics quality is not lost. Seaky (555079468) 1999-10-13 23:08:58 speed is accelerated, but the graphics quality is large, after all, 4 take 1! Is there a master? Hephaestus 1999-10-14 19:40:17 The screen transmission of many pure software I have seen is not using DirectX technology, but it has good efficiency. Seaky (555079468) 1999-10-14 22:35:02 I didn't ask for it to use DirectX, as long as you meet the requirements, what method can be! Masters, come on! Supplement date: 1999-10-18 01:15:15

Smalltalk 1999-10-14 22:36:34 I know how the screen transfers of these pure software multimedia teaching systems do, they use DDK to add existing Widows Video Device Driver plus traps, directly from the GDI data area Get the Bitmap on the display device, which is more than the GDI function and DirectX, but I have not studied. Seaky (555079468) 1999-10-14 22:51:43 Thank you SMALLTalk advice!

Supplement date: 1999-10-19 22:30:29

Tengel 1999-10-15 09:09:35 In fact, even if you use DDK, it is estimated that you don't reach Seaky's performance. I ask such a SEAKY so fast screen capture, what task wants to do? Seaky (555079468) 1999-10- 15 23:22:41 Want to complete a system with a "multimedia teaching system", currently trying to recommend SMALLTALK! Welcome to Tengel advice! My E-mail: Seaky@990.net ruthless swordsman (555079522) 1999-10-17 21:36:34 I also want to know how to do it, can I publish a detailed approach to the best solution? Seaky (555079468) 1999-10-18 01:20:48 I am currently testing various methods, I have not found the best solution in accordance with the requirements, and I will be announced after discovering!

Wide sea diving, sky high the birds to fly! --Seaky

Supplement date: 1999-10-21 22:36:40

Seaky (555079468) 1999-10-21 00:40:42 I have already found the answer! Is the use of DDK, but not finally completed! Thank you SmallTalk, Tengel, LWM, Kasper, Hwzhang, Hephaestus, ruthless swordsmen, all recent participation and advice, thank you!

Wide sea diving, sky high the birds to fly! --Seaky

转载请注明原文地址:https://www.9cbs.com/read-1490.html

New Post(0)