Jump to content


New swShader Demo


21 replies to this topic

#1 Nick

    Senior Member

  • Members
  • PipPipPipPip
  • 1227 posts
  • LocationOttawa, Ontario, Canada

Posted 30 September 2004 - 12:27 AM

You're the first to know! :D

Grab it here: swShader Project Page.

It demonstrates the capabilities of the swShader software renderer as a DirectX 9 compatible DLL. The actual application is an unmodified example from the DirectX 9.0b SDK. So all render calls are handled by this DLL, completely in software. For more information about swShader you can also visit the Main Homepage.

If you have any questions about it, feel free to ask!

#2 Dia

    DevMaster Staff

  • Administrators
  • 1121 posts

Posted 30 September 2004 - 03:24 AM

Nice work Nick! You continue to impress us. I've posted this news-worthy announcement on the main page. I'm downloading your demo right now and will try it out.

#3 cdgray

    New Member

  • Members
  • PipPip
  • 21 posts

Posted 30 September 2004 - 03:33 AM

cool..very cool. I've never seen this done before. Are you the first person?
Microsoft should buy this thing and use for their reference rasterizer. I do understand your reasons for not releasing the source code :D

You could easily beat the hardware by releasing a software implementation of Shader Model 4.0...way ahead of the hardware :sneaky: You made me comfortable that now I can do some researching without buying the actual hardware :)

thanks for the post.

#4 john

    Member

  • Members
  • PipPip
  • 84 posts

Posted 30 September 2004 - 03:38 AM

So what directx 9 features are you missing so far?
Are you planning on releasing an OpenGL software implementation (replacing the opengl.dll)? Given your modular design (i've looked at your code), it shouldn't be difficult to do it. But if you're done from implementing the directx features, you could start with opengl! I think it was a smart choice to start with DirectX because it is more oriented towards the hardware architecture than opengl. good job!

#5 Nick

    Senior Member

  • Members
  • PipPipPipPip
  • 1227 posts
  • LocationOttawa, Ontario, Canada

Posted 30 September 2004 - 05:55 AM

Thanks guys!

cdgray said:

I've never seen this done before. Are you the first person?
No, Oliver Weichhold was faster. He was able to show a software rendered Unreal (using the DirectX path) about two years ago. It was DirectX 8 compatible, and he called it SoftD3D. Never heard much about him after his article in ShaderX2. His performance wasn't bad, but it was all implemented in C++. Efficient shaders, and supporting millions of state combinations requires dynamic compilation technology like SoftWire.

Quote

Microsoft should buy this thing and use for their reference rasterizer. I do understand your reasons for not releasing the source code :D
The reference rasterizer will never be intended to be fast. :happy: My software is about 100 times faster, but slightly less accurate, and a bit buggy. The reference rasterizer is intended to be straightforward and rock-stable.

Quote

You could easily beat the hardware by releasing a software implementation of Shader Model 4.0...way ahead of the hardware :sneaky: You made me comfortable that now I can do some researching without buying the actual hardware :)
That's one of my goals with swShader, providing a library for experimentation with reasonable performance. Of course nothing beats the real hardware, but if I had to choose between 0.15 FPS from the reference rasterizer and 15 FPS from swShader...

john said:

So what directx 9 features are you missing so far?
The fixed-function pipeline is nearly finished, but the programmable pipeline has no interface yet. The functionality is about 90% finished, as you can see in my other demos, but it's not exposed through the DirectX DLL yet. Other than that there's still a big percentage of infrequently used functions that prevents some specialized applications from running. My best approach so far is to keep picking new sample applications and making them work one by one, I hope to start with games soon...

But first I will redesign my shader pipelines. They currently process one vertex and one pixel at a time. MMX and SSE will be used a lot more efficiently when processing them by four. The new rasterizer I presented in the Code Spotlight was the first step towards that. So the next few months I won't be adding new DirectX features, but I'm hoping this new implementation of the core will make it 50-100% faster.

Quote

Are you planning on releasing an OpenGL software implementation (replacing the opengl.dll)?
Yes, but not before the DirectX interface is completely finished. :unsure: For OpenGL there's already the Mesa3D project, and I don't want to be worrying about two APIs at the same time. It's still a hobby project...

#6 Nick

    Senior Member

  • Members
  • PipPipPipPip
  • 1227 posts
  • LocationOttawa, Ontario, Canada

Posted 01 October 2004 - 09:28 AM

Could some people post the FPS they get, and their processor specifications (model, cache, clock speed and FSB speed)? I'm interested to see which are good for this SIMD intensive work. Thanks!

16.28 FPS - Pentium M, 512 kB L2, 1.4 GHz, 533 Mhz FSB

#7 bladder

    DevMaster Staff

  • Members
  • PipPipPipPip
  • 1057 posts

Posted 01 October 2004 - 12:19 PM

p4 1.7ghz, 400mhz bus, IIRC the model is a HT capable but not HT enabled Xeon processor. Dunno about the L2 cache size.

[edit]
woops :blush: heh

fps = 10

thanks Nick
[/edit]

#8 JSoftware

    Member

  • Members
  • PipPip
  • 70 posts

Posted 01 October 2004 - 12:53 PM

fps: 15.94 Amd athlon xp "Barton" 2500+, 512kb l2, 1833 MHz,333mhz fsb
Peregrinus, expectavi pedos meos in cymbalis!

#9 Dia

    DevMaster Staff

  • Administrators
  • 1121 posts

Posted 01 October 2004 - 01:14 PM

tried it on my work machine:

Dual Processsor: PIII 1.4GHz (two processors, not HT)
RAM: 1GB
Bus: 133MHz
L2 Cache: 512KB
Running Window 2003 Server

FPS: ~12.5

#10 Nick

    Senior Member

  • Members
  • PipPipPipPip
  • 1227 posts
  • LocationOttawa, Ontario, Canada

Posted 01 October 2004 - 01:30 PM

Wow, I'm surprised I have the highest FPS (for now). :blink: Apparently Pentium M's are indeed very powerful even at low clock frequency. I'm dissapointed actually. I expected everyone to have an efficient 3 GHz processor that can render this at 30 FPS. :wink:

It's the shadow rendering that kills the performance. Without it, I get 60 FPS...

#11 anubis

    Senior Member

  • Members
  • PipPipPipPip
  • 2225 posts

Posted 01 October 2004 - 01:56 PM

i tried it on my notebook before i installed linux again for university so i can't provide any numbers but i was surprised to see the pentium-m perform so well
If Prolog is the answer, what is the question ?

#12 davepermen

    Senior Member

  • Members
  • PipPipPipPip
  • 1306 posts

Posted 01 October 2004 - 01:58 PM

10fps. 2.7ghz celeron.

i'll test out other systems, but for now, i'm on holidays, doing party and road trips, so i have no time.
davepermen.net
-Loving a Person is having the wish to see this Person happy, no matter what that means to yourself.
-No matter what it means to myself....

#13 moe

    Valued Member

  • Members
  • PipPipPip
  • 276 posts

Posted 01 October 2004 - 02:10 PM

I really wonder what I spent all that money on…? :sad:
I got a 3.2 GHz processor and all I get are 17.6 fps. Maybe it’s time to reinstall... :unsure:

Edit: sorry almost forgot, it crashes when i resize the window. thought you might want to know.

#14 JSoftware

    Member

  • Members
  • PipPip
  • 70 posts

Posted 01 October 2004 - 03:45 PM

yeah also crashes here
Peregrinus, expectavi pedos meos in cymbalis!

#15 john

    Member

  • Members
  • PipPip
  • 84 posts

Posted 01 October 2004 - 04:09 PM

Nick: it's pretty deceptive that you mention: "Using HAL" :)
It makes me think this is hardware-accelerated ;)

#16 Nick

    Senior Member

  • Members
  • PipPipPipPip
  • 1227 posts
  • LocationOttawa, Ontario, Canada

Posted 01 October 2004 - 05:55 PM

moe said:

Edit: sorry almost forgot, it crashes when i resize the window. thought you might want to know.
It's a known bug. I decided to release the demo as soon as possible. :blush: Another known bug is that there's sometimes a very thin line from the plane towards the shadow. It's related to rasterization precision, although I can't seem to reproduce it using synthetic tests.

I don't care much about these things. After all it's just the first DirectX 9 demo, and I'm still working on the new and improved pipelines...

Anyway, if you want higher resolution, simply recompile the SDK sample! :D

#17 Nick

    Senior Member

  • Members
  • PipPipPipPip
  • 1227 posts
  • LocationOttawa, Ontario, Canada

Posted 01 October 2004 - 06:01 PM

john said:

Nick: it's pretty deceptive that you mention: "Using HAL" :)
It makes me think this is hardware-accelerated ;)
Many applications won't run unless I completely let my software pretend it's a modern graphics card. :cool:

If you don't believe me, just replace your graphics card with one of those really old 2D PCI cards. :tongue:

#18 NomadRock

    Senior Member

  • Members
  • PipPipPipPip
  • 785 posts

Posted 01 October 2004 - 06:05 PM

16.8 fps
AMD Athlon 3000+
1GB 400Mhz ram

When in full screen at 1024x768 the frame rate drops to 2.6 fps
Jesse Coyle

#19 Nick

    Senior Member

  • Members
  • PipPipPipPip
  • 1227 posts
  • LocationOttawa, Ontario, Canada

Posted 01 October 2004 - 06:47 PM

NomadRock said:

When in full screen at 1024x768 the frame rate drops to 2.6 fps
Now try the reference rasterizer. :wink:

I know I still have a long way to go... But the first experiments with the new raterizer are amazing. While I'm currently processing stencil operations one pixel at a time, the new rasterizer will allow me to do eight in parallel. It also allows efficient overdraw reduction. I'm not sure what the effective speedup will be, but I'm still aiming at 30 FPS at 640x480.

#20 moe

    Valued Member

  • Members
  • PipPipPip
  • 276 posts

Posted 01 October 2004 - 09:19 PM

Quote

If you don't believe me, just replace your graphics card with one of those really old 2D PCI cards
The graphic card should be completely irrelevant since it is a software renderer, or am I missing something?

Quote

I'm still aiming at 30 FPS at 640x480
We all trust in your skills and therefore I am confident you’ll be there soon. :yes:





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users