I have an existing Direct3D9 based application that uses the Direct3D9
software rasterizer (rgb9rast) to perform a simple thumbnail generation of 3D
scenes. The thumbnails are dumped to JPGs for use in a web based GUI. The
application is launched from a tomcat running in session 0, so it also
launches in session 0. The system can be headless, so no user may log into
it. I'm aware of session 0 isolation would prevent hardware from being
available there, but this doesn't use hardware. It is using the software
rasterizer.
Is this a bug or misfeature of RegisterSoftwareDevice? Is there a way
around this that does not require a user to log on so there's another logon
session to work from?
--Johno
=?Utf-8?B?am9obm8=?= <jo...@discussions.microsoft.com> spake the secret code
<9047FD74-9519-4E11...@microsoft.com> thusly:
>I have an existing Direct3D9 based application that uses the Direct3D9
>software rasterizer (rgb9rast) to perform a simple thumbnail generation of 3D
>scenes. [...]
Umm... near as I can tell, rgb9rast is something installed by the
.NET Framework 3 or 3.5.
You should never need to call RegisterSoftwareDevice yourself.
A technology like "WARP" (Windows Advanced Rasterization Platform) is
more like what you should be using, but that is for D3D10 and higher,
not D3D9.
Look in the DirectX Graphics Documentation (August 2009) section
titled "How To: Create a WARP Device".
--
"The Direct3D Graphics Pipeline" -- DirectX 9 draft available for download
<http://legalizeadulthood.wordpress.com/the-direct3d-graphics-pipeline/>
Legalize Adulthood! <http://legalizeadulthood.wordpress.com>
I believe that's the same rasterizer, but it's not specific to .NET.
Microsoft provides a software rasterizer download for distribution to XP
and lesser systems. The download is still available as "Software
Rasterizer for the Microsoft DirectX 9.0 Software Development Kit (SDK)":
With Vista and beyond, the software rasterizer comes with the OS so
there's nothing to install.
> You should never need to call RegisterSoftwareDevice yourself.
>
The directions that come with the redistributable (rgbrast.htm)
specifically state otherwise:
To use the Microsoft Software Rasterizer an application must do the
following:
1) Perform a LoadLibrary of the Microsoft Software Rasterizer.
HModule hRast =
LoadLibrary("C:\Windows\System32\RGB9Rast_1.dll");
2) Get the Microsoft Software Rasterizer entry point.
FARPROC D3D9GetSWInfo = GetProcAddress( hRast, "D3D9GetSWInfo");
3) Pass the Microsoft Software Rasterizer entry point to the Direct 3D
9.0 runtime.
IDirect3D9::RegisterSoftwareDevice( D3D9GetSWInfo);
> A technology like "WARP" (Windows Advanced Rasterization Platform) is
> more like what you should be using, but that is for D3D10 and higher,
> not D3D9.
>
I'm mostly familiar with what DX11 offers but a DX9 to DX11 conversion
project is not in the cards right now. It would take a few months of
programming and QA to switch from D3D9 to D3D11. That would be a
ridiculous amount of work just to get back something that works fine in
XP and is likely an oversight.
--Johno
John <johnperiodorr@scalaperiodcom> spake the secret code
<uaUaaRx...@TK2MSFTNGP05.phx.gbl> thusly:
>I believe that's the same rasterizer, but it's not specific to .NET.
>Microsoft provides a software rasterizer download for distribution to XP
>and lesser systems. The download is still available as "Software
>Rasterizer for the Microsoft DirectX 9.0 Software Development Kit (SDK)":
>
>http://www.microsoft.com/downloads/details.aspx?familyid=57d03491-6c49-4429-bff7-130408b5f410&displaylang=en
Interesting, I was unaware of this and its been around for 4 years :-).
If you have an MSDN subscription, I would use one of your technical
support incidents on this to get it resolved. It sounds like it could
just be a bug in the way they're doing things either in the software
rasterizer or in the D3D runtime because they're not expecting that the
API will be used in this scenario.
>> http://www.microsoft.com/downloads/details.aspx?familyid=57d03491-6c49-4429-bff7-130408b5f410&displaylang=en
>
> Interesting, I was unaware of this and its been around for 4 years :-).
>
> If you have an MSDN subscription, I would use one of your technical
> support incidents on this to get it resolved. It sounds like it could
> just be a bug in the way they're doing things either in the software
> rasterizer or in the D3D runtime because they're not expecting that the
> API will be used in this scenario.
>
OK, will do. Thanks for your help!
--Johno
Just to follow up, as a result of my MSDN technical support incident,
Microsoft issued this:
http://support.microsoft.com/kb/978635
D3D9 in Vista and Windows 7 fails from a service. This is on purpose
and will not be fixed. Although that article doesn't specifically state
it, this is true even with a software rasterizer registered via
IDirect3D9::RegisterSoftwareDevice.
--Johno