Mobile Programming
I am planning on buying a Dell Inspiron Laptop with:
15" Ultra XGA monitor
1.2GHz Pentium 3
512MB Ram
32MB Gforce2GO
60GB Hard Drive
Windows XP Professional
Visual C++ Enterprise or Professional
Has anyone had any problems programming games with DirectX on laptops? This would be my first laptop and im not familiar with the compatibility of the Compiler VS. Operating system VS. The hardware.
That setup should be fine.
The usual problem people encounter is with the the graphics card not having hardware 3D rendering support. But with a GeForce 2 Go you''ll be fine. The OS etc are also fine.
As for specific programming issues you''ll encounter:
- Power management - you need to handle the Windows messages you get regarding this and make sure your code handles them properly (for example save the game when the machine goes into suspend mode due to a low battery). WM_POWERBROADCAST and WM_COMMAND are the two main messages you''ll be interested in.
- Docking - laptops can be "docked" where they get connected to a full size monitor, proper keyboard etc. For the monitor, to the code it looks like a computer with multiple monitors (LCD is one, fullsize monitor is other). Same for keyboards etc - they''ll show up as multiple devices.
- Speed - the CPUs and other peripherals run at variable speeds depending on how much life is left in the battery. The CPU for example will step down to a slower speed when it senses a low battery. For this reason, things like hand coded ASM RDTSC timers go wrong (using QueryPerformanceCounter is the way to go).
--
Simon O''''Connor
Creative Asylum Ltd
www.creative-asylum.com
The usual problem people encounter is with the the graphics card not having hardware 3D rendering support. But with a GeForce 2 Go you''ll be fine. The OS etc are also fine.
As for specific programming issues you''ll encounter:
- Power management - you need to handle the Windows messages you get regarding this and make sure your code handles them properly (for example save the game when the machine goes into suspend mode due to a low battery). WM_POWERBROADCAST and WM_COMMAND are the two main messages you''ll be interested in.
- Docking - laptops can be "docked" where they get connected to a full size monitor, proper keyboard etc. For the monitor, to the code it looks like a computer with multiple monitors (LCD is one, fullsize monitor is other). Same for keyboards etc - they''ll show up as multiple devices.
- Speed - the CPUs and other peripherals run at variable speeds depending on how much life is left in the battery. The CPU for example will step down to a slower speed when it senses a low battery. For this reason, things like hand coded ASM RDTSC timers go wrong (using QueryPerformanceCounter is the way to go).
--
Simon O''''Connor
Creative Asylum Ltd
www.creative-asylum.com
Regarding the timing, when the cpu speed steps down, wouldn''t the performance counter''s frequency change? Hence would you have to keep calling QueryPerformanceFrequency every so often to make sure your calculations were accurate, or do the windows messages also let you know about changes in processor speed also?
AFAIK Windows will make sure that even if the CPU speed does change, the QueryPerformanceCounter call will always return it''s values at the same frequency regardless of whether the CPU has stepped down. According to MS QPC() doesn''t usually use RDTSC, it prefers to use alternative hardware timers (which won''t change when the CPU speed steps).
--
Simon O''''Connor
Creative Asylum Ltd
www.creative-asylum.com
--
Simon O''''Connor
Creative Asylum Ltd
www.creative-asylum.com
Well. If someone is playing games on a laptop, common sense would be to use a power cord.
I have an older Compaq Armada laptop and had no problems creating applications on it. Just do not get too hardware specific.
I have an older Compaq Armada laptop and had no problems creating applications on it. Just do not get too hardware specific.
quote:Original post by GoofProg
Well. If someone is playing games on a laptop, common sense would be to use a power cord.
Consider the bored businessman sat in an airport who has a 2 hour wait for a delayed flight... it''s quite likely he''d want to play a game to kill some time and wouldn''t have access to a power outlet. And when he gets on the plane and wants to continue playing...
Funnily enough a game I wrote the 3D engine and other code for (Pac-Man:AIT) is used in nVidia''s GeForce 2 Go promotion...
http://www.nvidia.com/view.asp?PAGE=pg_20010528778429
[Note laptop on plane - also note what he''s playing ]
http://www.nvidia.com/view.asp?IO=feature_entertain
--
Simon O''''Connor
Creative Asylum Ltd
www.creative-asylum.com
Thanks for the useful information. I probably wont be doing to my ap-building while actually on the run. I just needed to bring my hardware with me to another location and a laptop seemed the logical step. So most of the time I will be cord powered.
I did have another question though. Is DirectX 8 compatible with the items I listed or will I have to fall back to some older function calls.
I did have another question though. Is DirectX 8 compatible with the items I listed or will I have to fall back to some older function calls.
Yes DirectX 8 is fully compatible with the items you''ve listed. In fact, WindowsXP contains DirectX 8.1 as standard.
--
Simon O''''Connor
Creative Asylum Ltd
www.creative-asylum.com
--
Simon O''''Connor
Creative Asylum Ltd
www.creative-asylum.com
Be wary of Inspirons. I''ve read many reviews that called them flimsy and many more that said they creaked when you try to move them. Go to dell and look at the support website to get a sample of some of the problems you might have. Also, I read on Dell''s site that an acceptable rate of dead pixels is about 6 or so for every laptop. I don''t think I''d want any myself...
quote:Original post by S1CA
Consider the bored businessman sat in an airport who has a 2 hour wait for a delayed flight... it''s quite likely he''d want to play a game to kill some time and wouldn''t have access to a power outlet. And when he gets on the plane and wants to continue playing...
Funnily enough a game I wrote the 3D engine and other code for (Pac-Man:AIT) is used in nVidia''s GeForce 2 Go promotion...
--
Simon O''Connor
Creative Asylum Ltd
www.creative-asylum.com
Wow... those PacMan:AIT screenshots look eerily familiar... (and they also look rather groovey, of course!) :-)
I wonder if we had the same producer (from Hasbro Interactive) at some point in the past... Anyhows, looks good!
Apologies - I realise I have gone totally off-topic! As for the laptop system outlined above it would be ideal for the on-the-move coder and I would certainly recommend that anyone serious about game coding should try and get a decent laptop.
Cheers,
Sharky
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement