Click here to Skip to main content
16,006,013 members
Home / Discussions / C#
   

C#

 
Generalversioning problem Pin
devvvy7-Aug-03 22:57
devvvy7-Aug-03 22:57 
GeneralThread doesn't start with VS .NET 2003 Pin
MeisterBiber7-Aug-03 21:52
MeisterBiber7-Aug-03 21:52 
GeneralRe: Thread doesn't start with VS .NET 2003 Pin
Rein Hillmann8-Aug-03 5:38
Rein Hillmann8-Aug-03 5:38 
GeneralMulti-Threaded Programming Pin
monrobot137-Aug-03 17:12
monrobot137-Aug-03 17:12 
GeneralRe: Multi-Threaded Programming Pin
J. Dunlap7-Aug-03 17:35
J. Dunlap7-Aug-03 17:35 
GeneralRe: Multi-Threaded Programming Pin
monrobot138-Aug-03 3:15
monrobot138-Aug-03 3:15 
GeneralRe: Multi-Threaded Programming Pin
J. Dunlap8-Aug-03 9:49
J. Dunlap8-Aug-03 9:49 
GeneralBitBlt performance in C# Pin
CyberKewl7-Aug-03 16:52
CyberKewl7-Aug-03 16:52 
I'm using the following code to capture a screenshot :

Image myImage = new Bitmap(Screen.PrimaryScreen.Bounds.Width, Screen.PrimaryScreen.Bounds.Height);

Graphics gr1 = Graphics.FromImage(myImage);

IntPtr dc1 = gr1.GetHdc();

IntPtr dc2 = GetDC(GetDesktopWindow());

BitBlt(dc1, 0, 0, Screen.PrimaryScreen.Bounds.Width, Screen.PrimaryScreen.Bounds.Height, dc2, 0, 0, 13369376);

gr1.ReleaseHdc(dc1);
GC.Collect();
return myImage;


I'm trying to capture a screenshot of the entire desktop and transferring it to a remote PC (to create a program like PcAnywhere). The thing is, i set my screenshot timer to something like 450 ms and on my machine (Athlon XP 2000+), it uses up around 30% of the CPU power. However, if i test it on my old P3-700 Mhz machine, the CPU utilisation is very high, ranging between 75-90%.

Is there any way to reduce the CPU utilisation (maybe like reducing the color depth of the image? but how)?
GeneralRe: BitBlt performance in C# Pin
J. Dunlap7-Aug-03 17:45
J. Dunlap7-Aug-03 17:45 
GeneralRe: BitBlt performance in C# Pin
CyberKewl7-Aug-03 21:21
CyberKewl7-Aug-03 21:21 
GeneralRe: BitBlt performance in C# Pin
Ista8-Aug-03 6:26
Ista8-Aug-03 6:26 
GeneralChanging a form's title Pin
eggie57-Aug-03 15:17
eggie57-Aug-03 15:17 
GeneralRe: Changing a form's title Pin
J. Dunlap7-Aug-03 15:20
J. Dunlap7-Aug-03 15:20 
GeneralRe: Changing a form's title Pin
eggie57-Aug-03 15:30
eggie57-Aug-03 15:30 
GeneralRe: Changing a form's title Pin
Rein Hillmann7-Aug-03 21:11
Rein Hillmann7-Aug-03 21:11 
GeneralRe: Changing a form's title Pin
freshthinking8-Aug-03 0:07
freshthinking8-Aug-03 0:07 
GeneralColor or Colour Pin
totig7-Aug-03 12:23
totig7-Aug-03 12:23 
GeneralRe: Color or Colour Pin
J. Dunlap7-Aug-03 12:51
J. Dunlap7-Aug-03 12:51 
GeneralHandle mouse move events in C# Pin
sumeat7-Aug-03 9:20
sumeat7-Aug-03 9:20 
GeneralRe: Handle mouse move events in C# Pin
Nnamdi Onyeyiri7-Aug-03 11:10
Nnamdi Onyeyiri7-Aug-03 11:10 
GeneralRe: Handle mouse move events in C# Pin
sumeat7-Aug-03 11:42
sumeat7-Aug-03 11:42 
GeneralRe: Handle mouse move events in C# Pin
Ista7-Aug-03 16:08
Ista7-Aug-03 16:08 
Generalmore datagrid q's: select row & tab down Pin
mikemilano7-Aug-03 9:09
mikemilano7-Aug-03 9:09 
GeneralRe: more datagrid q's: select row & tab down Pin
mikemilano7-Aug-03 9:20
mikemilano7-Aug-03 9:20 
GeneralRe: more datagrid q's: select row & tab down Pin
Ista7-Aug-03 17:34
Ista7-Aug-03 17:34 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.