Jump to content

  • Log In with Google      Sign In   
  • Create Account

#Actualsamoth

Posted 23 November 2012 - 07:11 AM

I wouldn't say "no point in learning CUDA". It is by far the most high-performance API available. If you are crunching a lot of numbers and need ultra-high performance, then you will certainly want to use CUDA. I don't have any concrete numbers at hand now, but I remember having heard about noticeable differences (something like 10-15%? don't nail me down on that) between CUDA and OpenCL on the same hardware, doing the same calculation.

If you want to crunch numbers and don't want to depend on one vendor, use OpenCL.

If you just want to add "some special calculation and simulation" to your graphics and you make DX11 hardware a minimum spec, you're good with using compute shader. Otherwise, use OpenCL, which works fine (with 99% of its features) on DX10 class hardware.
Or, just do the calculations in the vertex/pixel shader, if the structure of the data and the nature of the calculations allows for it. For most people, most of the time, that's just good enough, and it's the least painful.

If you just want to write a "game with some physics", you probably want to use an already functioning and tested physics engine, preferrably one that doesn't run on only one specific hardware vendor. Bullet is an example of such a thing.
Really, if this is your goal, use something that already works. It's by no means a trivial task to write your own physics engine.

#1samoth

Posted 23 November 2012 - 07:09 AM

I wouldn't say "no point in learning CUDA". It is by far the most high-performance API available. If you are crunching a lot of numbers and need ultra-high performance, then you will certainly want to use CUDA.

If you want to crunch numbers and don't want to depend on one vendor, use OpenCL.

If you just want to add "some special calculation and simulation" to your graphics and you make DX11 hardware a minimum spec, you're good with using compute shader. Otherwise, use OpenCL, which works fine (with 99% of its features) on DX10 class hardware.
Or, just do the calculations in the vertex/pixel shader, if the structure of the data and the nature of the calculations allows for it. For most people, most of the time, that's just good enough, and it's the least painful.

If you just want to write a "game with some physics", you probably want to use an already functioning and tested physics engine, preferrably one that doesn't run on only one specific hardware vendor. Bullet is an example of such a thing.
Really, if this is your goal, use something that already works. It's by no means a trivial task to write your own physics engine.

PARTNERS