Java-Gaming.org    
Featured games (81)
games approved by the League of Dukes
Games in Showcase (499)
Games in Android Showcase (118)
games submitted by our members
Games in WIP (567)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Using software rendering instead of GPU rendering?  (Read 2807 times)
0 Members and 1 Guest are viewing this topic.
Offline kpars

JGO Wizard


Medals: 81
Projects: 4
Exp: 3 years


Extreme Typist.


« Posted 2013-05-06 20:39:42 »

I'm currently writing a Doom-esque 2.5D game at the moment, not using any libraries such as LWJGL or JOGL. Would it still be okay to use the games software rendering instead of moving on to LWJGL using GPU rendering? Any help is appreciated  Grin.

Also to note: I'm still a slight-bit new, so if I get a few things wrong let me know.

Offline kappa
« League of Dukes »

JGO Kernel


Medals: 77
Projects: 15


★★★★★


« Reply #1 - Posted 2013-05-06 22:01:10 »

Shouldn't be a problem on todays CPU's, however seems a bit of a waste for the GPU to just sit there when you can offload work to it and free up the CPU for other tasks.
Offline gouessej
« Reply #2 - Posted 2013-05-07 11:46:53 »

Hi

I used software rendering at the very beginning of my project in 2006. The engine I used was called d3caster, it uses a very basic raycasting algorithm. There are more efficient solutions even in this field, 3DzzD is very fast and supports both hardware and software rendering. However, I agree with kappa. You can get a decent frame rate even on low end machines if and only if you use very simple meshes. Todays CPUs move the limits further but when you use Java, some operations are already hardware accelerated "under the hood" and your rendering will always be noticeably slower on the CPU anyway.

I have used JOGL for several years, it contains some nice renderer quirks to work around some very famous driver bugs which drives it safer than home made OpenGL plain C/C++ code except if you are a specialist of drivers :s The very first version of my game only has 2D ennemies in a flat 3D level, a bit like Wolfenstein and hardware acceleration gave me a huge boost, the game was initially unplayable in full screen mode, it was so slow, I got only one frame every 2 seconds with software rendering  Sad

Use software rendering only if you don't aim low end CPUs or if your graphics are extremely rudimentary but I don't see the point except that you don't need to sign your application.

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline theagentd
« Reply #3 - Posted 2013-05-07 12:54:30 »

Shouldn't be a problem on todays CPU's, however seems a bit of a waste for the GPU to just sit there when you can offload work to it and free up the CPU for other tasks.
You could write a software renderer using OpenCL... >_>

Myomyomyo.
Offline quew8

JGO Coder


Medals: 30



« Reply #4 - Posted 2013-05-08 18:08:12 »

@theagentd - That sounds very cool but it might actually be slower than just cpu rendering. You would have to send the info to opencl on the gpu then it works stuff out, then it has to send it back to the cpu so you can send it back to the gpu to tell it to be rendered. Or maybe I'm missing something.
Offline matheus23

JGO Kernel


Medals: 108
Projects: 3


You think about my Avatar right now!


« Reply #5 - Posted 2013-05-08 18:17:12 »

@theagentd - That sounds very cool but it might actually be slower than just cpu rendering. You would have to send the info to opencl on the gpu then it works stuff out, then it has to send it back to the cpu so you can send it back to the gpu to tell it to be rendered. Or maybe I'm missing something.

If I look at openGL it looks like it's likely not slower Smiley I know, openCL and openGL is not the same thing, but the difference shouldn't be too big.

See my:
    My development Blog:     | Or look at my RPG | Or simply my coding
http://matheusdev.tumblr.comRuins of Revenge  |      On Github
Offline theagentd
« Reply #6 - Posted 2013-05-08 18:23:26 »

@theagentd - That sounds very cool but it might actually be slower than just cpu rendering. You would have to send the info to opencl on the gpu then it works stuff out, then it has to send it back to the cpu so you can send it back to the gpu to tell it to be rendered. Or maybe I'm missing something.
I was obviously kidding. That's exactly what OpenGL is for.

@theagentd - That sounds very cool but it might actually be slower than just cpu rendering. You would have to send the info to opencl on the gpu then it works stuff out, then it has to send it back to the cpu so you can send it back to the gpu to tell it to be rendered. Or maybe I'm missing something.
If I look at openGL it looks like it's likely not slower Smiley I know, openCL and openGL is not the same thing, but the difference shouldn't be too big.
That most likely wouldn't be the case. There are lots of fixed functionality hardware between shader stages in OpenGL. There are hardware rasterizers that can determine which pixels that lie inside a triangle using multiple sample points, hardware interpolators for interpolating vertex attributes across a triangle for each pixel and most importantly ROP (raster output) units that ensure high performance while synchronizing the order of pixel writes. I bet that there's even more hardware than I've mentioned under the hood that OpenGL uses that isn't exposed in OpenCL.

Myomyomyo.
Offline Danny02
« Reply #7 - Posted 2013-05-08 18:47:17 »

doing a software renderer on the GPU is not a dumb idea. NVidia did some research in this direction, first they created a software rasterizer with CUDA which got at about 1/10th the speed of the normal hardware rendering. Then they did a lot of research with raytracing on the GPU which is a lot faster then doing it on the CPU.

http://de.slideshare.net/NVIDIA/alternative-rendering-pipelines-on-nvidia-cuda

It is not something which you can be used for games atm, because you can only use it for not so big scenes and your customoers would require a high and graphicscard.

They are using it in the movie industry for pre-vis for example.

On the other hand one can always use some sort of raycasting in a shader for some special rendering techniques, which is some sort of software rendering.
Offline relminator
« Reply #8 - Posted 2013-05-09 02:33:50 »

There are some things that are easier to do in software( probably more effecient too).  Like swirling background I did on this gfx effect.

rel.phatcode.net/junk.php?id=142

Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

Pippogeek (39 views)
2014-09-24 16:13:29

Pippogeek (30 views)
2014-09-24 16:12:22

Pippogeek (19 views)
2014-09-24 16:12:06

Grunnt (44 views)
2014-09-23 14:38:19

radar3301 (27 views)
2014-09-21 23:33:17

BurntPizza (63 views)
2014-09-21 02:42:18

BurntPizza (32 views)
2014-09-21 01:30:30

moogie (40 views)
2014-09-21 00:26:15

UprightPath (50 views)
2014-09-20 20:14:06

BurntPizza (54 views)
2014-09-19 03:14:18
List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06

List of Learning Resources
by SilverTiger
2014-07-31 11:54:12

HotSpot Options
by dleskov
2014-07-08 01:59:08
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!