Skip to main content
GameDev.net gamedev.net
🔒 Locked

DirectX on XP on an intel macbook pro

Started by hotpixel Jun 29, 2009 at 4:50 AM 18 replies 1.4k views
Original Post
hotpixel
hotpixel
Hi ya, Wasn't quite sure where to post this but thought perhaps it might be a DX thing (feel free to move). I am developing a small(ish) casual puzzle game that I am trying to optimise on a few systems, going through the basic checks on various PCs which I would like it to run on. I have a Sony Vaio about 4 years old, 1.86Ghz single core Pentium M, 1Gig of ram, an ATI Mobility Radeon X700 with 256MB vRam, GPU speed of 350Mhz and only supports shader model 2.0. Took me a while but I optimised it for this sort of spec and it runs fine, no lagging. ...so I decided to try it on an Intel Macbook pro which is happily running XP, it was top spec about a year ago. Dual core 2.6Ghz, 3GB ram, GeForce 8600M, 512Mb vRam, 475MHz GPU speed, memory and shader speed nearly twice that, it supports shader model 4.0.... AND IT RUNS LIKE A DOG! It even struggles to rotate a 2D sprite on the title screen, before any 3D is even loaded!!! What is going on? My question is if there are any known issues with DX on the intel macs, if there is any support I am failing to write into my device object? The graphics driver is Intel mac specific, you can't just download the latest nVidia graphics driver so I am thinking this might be the case. This machine should tear up my game at 1080p and still have resources left to play COD4!
hotpixel
hotpixel
Someone in the office has just pointed out that dogs can run quite fast, allow me to clarify... it doesn't. Perhaps it's a 3 legged dog.
Evil Steve
Evil Steve
Have you tried using PIX and/or NVPerfHUD to profile what's going on?
hotpixel
hotpixel
Yea, PIX, it looks fine, nothing jumping out at me. Everything is just taking that little bit longer to process, Really odd :(
hotpixel
hotpixel
The other thing is that the mac does have the SDK on it, not the distribution version of DX, that wouldn't make a difference... would it?
Codeka
Codeka
It would if you're running the Debug runtime, use the DirectX Control Panel program to make sure it's using the Release runtime.
hotpixel
hotpixel
Yea I did make sure, I am using the debug libraries but then I am on both systems so if it was gong to make it slow it would be on both systems.
Evil Steve
Evil Steve
Quote:
Original post by hotpixel
Yea I did make sure, I am using the debug libraries but then I am on both systems so if it was gong to make it slow it would be on both systems.
Not necessarily. You really can't compare performance in debug mode - try them both in release and see if it's still slow.
hotpixel
hotpixel
Okay I'll give it a go but I gotta fix my release settings first as it doesn't compile :'(
Evil Steve
Evil Steve
Quote:
Original post by hotpixel
Okay I'll give it a go but I gotta fix my release settings first as it doesn't compile :'(
Just to make sure - there's the D3D debug runtimes, which are accessed via the DirectX Control Panel, and there's also a debug or release version of your app.
hotpixel
hotpixel
the DX control panel is always in runtime, it really messes with my app if its in debug, my models disappears! My VS project has been running in debug where I am now trying to get the release build to work.
Erik Rufelt
Erik Rufelt
Quote:
Original post by hotpixel
It even struggles to rotate a 2D sprite on the title screen, before any 3D is even loaded!!! What is going on?


When it's that slow it's almost always a reference device.. check so that you don't have it set to automatically switch to reference. (Make sure you force hardware or get a failure return code if it doesn't work).
hotpixel
hotpixel
Well that's what I thought but it doesn't do it all the time, the odd occasion and very rarely it runs fine and I'm passing in a hardware flag. I'll do a check on the update code see if its switching
hotpixel
hotpixel
does anyone know how I query a dx device for hardware or software vertex processing?
Evil Steve
Evil Steve
Quote:
Original post by hotpixel
the DX control panel is always in runtime, it really messes with my app if its in debug, my models disappears! My VS project has been running in debug where I am now trying to get the release build to work.
That's a good sign that something is wrong and your code won't work on some drivers. I'd recommend fixing that bug soon, since it's entirely possible that this is causing your problems.

Quote:
Original post by hotpixel
does anyone know how I query a dx device for hardware or software vertex processing?
For fixed function, you check the D3DCAPS9 struct (From IDirect3D9::GetDeviceCaps()), and see if DevCaps includes the D3DDEVCAPS_HWTRANSFORMANDLIGHT flag.
For vertex shaders, you need to check the VertexShaderVersion cap in the D3DCAPS9 struct.
hotpixel
hotpixel
Nope, hardware and it supports my shader version
Evil Steve
Evil Steve
How do the DirectX SDK samples perform? Do they work ok?
hotpixel
hotpixel
yea seem to be fine, it struggles a bit on the parallax oscillation mapping 90fps but more than acceptable and I have nothing that complex in my app.

It sounds a bit odd but its behaving differently to just the average slow lag. The camera seems to jump behind it, as though it is pausing on something, when the game is slow everything just grinds but its like a pause every few frames... I must be missing something in PIX...
gekko
gekko
Quote:
Original post by hotpixel
does anyone know how I query a dx device for hardware or software vertex processing?


DX SDK ships with a "Caps Viewer" program, which allows you to check all that stuff much easier than altering your code and recompiling.

If it helps (doubt it), I work on a slightly older MBP (ATI card) running Windows XP through Boot Camp and have never had any issues related to the DX SDK.
-- gekko
hotpixel
hotpixel
Thanks guys, really appreciate your help. I'll have a look into the caps viewer tomorrow, looks pretty helpful from what I can see, and interesting you had a MBP on bootcamp with no issues however not good for me :(... I hate debug stage. I think just try it on a wider range of systems.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.