Giorgio Tino
2008-03-15 19:15:10 UTC
Hi,
I have a big problem that I've been trying to solve lately and that
drives me crazy. First of all, I'm using Managed DirectX with C#, the
latest version available. It looks like after a LostDevice, lights are
not reset properly on Vista. All the meshes are solid black. This
happens on Vista only. On XP, I'm able to lose the device as many times
as I want and everything works perfectly ok. On Vista instead everything
is reset in the right way but the lights. I've been searching on the
internet and it looks loke I'm not the only one with the same problem
(http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=1335832&SiteID=1),
and probably the Samples shipped with the SDK have the same problem too.
I did not try to recreate the Device from scratch after every
DeviceLost (we'll I'm having some trouble and of course I guess it will
be way slower than just following the Reset() pattern anyway), because I
'hope' it is a well known problem, and that I'm just doing something
wrong... I actually I do not know if the problem is that 'lights are
not reset' or if the Mesh I'm using (Mesh.Sphere, nothing more than
that) and that I RECREATE in every Refresh has some problem (I've tryed
to ComputeNormals() and nothing changed). Maybe I'm missing some
initialization that is not required on XP (just because I'm lucky)...
I'd just like to know if someone has an idea about that...
THANKS A LOT!
Giorgio Tino
P.S. For the version 2.0 of my application I'm thinking about switching
to XNA... Is it easier in XNA to manage the DeviceLost/Reset scenario???
I have a big problem that I've been trying to solve lately and that
drives me crazy. First of all, I'm using Managed DirectX with C#, the
latest version available. It looks like after a LostDevice, lights are
not reset properly on Vista. All the meshes are solid black. This
happens on Vista only. On XP, I'm able to lose the device as many times
as I want and everything works perfectly ok. On Vista instead everything
is reset in the right way but the lights. I've been searching on the
internet and it looks loke I'm not the only one with the same problem
(http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=1335832&SiteID=1),
and probably the Samples shipped with the SDK have the same problem too.
I did not try to recreate the Device from scratch after every
DeviceLost (we'll I'm having some trouble and of course I guess it will
be way slower than just following the Reset() pattern anyway), because I
'hope' it is a well known problem, and that I'm just doing something
wrong... I actually I do not know if the problem is that 'lights are
not reset' or if the Mesh I'm using (Mesh.Sphere, nothing more than
that) and that I RECREATE in every Refresh has some problem (I've tryed
to ComputeNormals() and nothing changed). Maybe I'm missing some
initialization that is not required on XP (just because I'm lucky)...
I'd just like to know if someone has an idea about that...
THANKS A LOT!
Giorgio Tino
P.S. For the version 2.0 of my application I'm thinking about switching
to XNA... Is it easier in XNA to manage the DeviceLost/Reset scenario???