Is OpenCL what I need?

Started by
10 comments, last by tapped 11 years, 3 months ago

[quote name='ic0de' timestamp='1356794744' post='5015438']
ran it on a 25mhz 386sx just as fast
[/quote]

You can't really compare it directly. For example CPU speeds increased much more than memory speed did.

And thats where graphic cards have the advantage, while the gpu is glocked much lower than a cpu it has faster memory with more bandwidth. Of course having hundreds of processing units also helps.

But the memory is really where it gets difficult, because if you double your vertical and horizontal resolution you've already quadrupled the screen buffer size. Which means you need four times the bandwidth. Delta Force, Commance, Outcast used maybe 640x480 (307200 pixels), maybe more, maybe less, nowadays I run games in 1920x1200 (2304000 pixels). That's 7 times the number of pixels, not counting anti-aliasing. And almost all the time the work done per pixel has also increased.

Just an example, there is this demo called heaven seven which used realtime-raytracing (cpu). It's from mid 2000. Now more than 12 years later there is still nobody that is using realtime-raytracing in a broader scale.

[quote name='ic0de' timestamp='1356675956' post='5014999']
The problem with GLSL/HLSL is that they are deeply integrated into the OpenGL/D3D pipeline.
[/quote]

While it's true, using some tricks or hacks you can do alot of things in the shader, that where never to be done on it.

If you need an example, take a look at my (still work in progress) website. Or look around the web for more examples of creative shader usage. (The examples you can find on the web are probably less hackish...)

Advertisement
OpenCL is likely not the right solution. You will end up spending a lot of time with setup, and use of OpenCL. Furthermore, is the CL buffer mapping to GL buffer slow. So the bottleneck on the CPU implementation, may also be the bottleneck when using OpenCL for rendering.
I have to admit that OpenCL is more stylish, and in many ways easier for others to understand. However it takes time to become familiar with it, so why not use GLSL?

While it's true, using some tricks or hacks you can do alot of things in the shader, that where never to be done on it.If you need an example, take a look at my (still work in progress) website. Or look around the web for more examples of creative shader usage. (The examples you can find on the web are probably less hackish...)
To support shadowomf, i claim that you can do the same things in a shader as in OpenCL. You only need to think innovative, in other words use framebuffers, textures and transform feedbacks, then you can do pretty much whatever you want.

Good luck

This topic is closed to new replies.

Advertisement