Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Add Compute Shaders Support  (Read 8872 times)

0 Members and 1 Guest are viewing this topic.

tony_kero

  • Newbie
  • *
  • Posts: 7
    • View Profile
Add Compute Shaders Support
« on: July 15, 2016, 11:27:06 pm »
Hi there, i think it would be great to implement Compute Shaders, which come from OpenGL 4.0 Shading Language i guess, because it's a feature which is clearly something very interesting/powerful, it adds a GPGPU Computing feature to OpenGL Shaders, and this is more easy-to-use than CUDA or OpenCL Libraries and moreover includes graphics object access.
I have seen the recent geometry shader support for sfml, and i think it would be nice to implement the Compute Shaders too.


binary1248

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1405
  • I am awesome.
    • View Profile
    • The server that really shouldn't be running
Re: Add Compute Shaders Support
« Reply #1 on: July 15, 2016, 11:47:00 pm »
Geometry shaders have been available for 7 years and thus are supported on a wider range of hardware than compute shaders which have only been available for 4 years. Probably the most common chipset currently in use is Intel's integrated graphics and Intel HD Graphics have only supported compute shaders since Haswell. As such, as nice as support would be, there isn't a realistically large audience that would currently benefit from compute shader support via SFML. This does not exclude directly managing them using raw OpenGL yourself though. That is always a possibility while using SFML for everything else.
SFGUI # SFNUL # GLS # Wyrm <- Why do I waste my time on such a useless project? Because I am awesome (first meaning).

ShqrdX

  • Newbie
  • *
  • Posts: 12
    • View Profile
Re: Add Compute Shaders Support
« Reply #2 on: July 16, 2016, 12:01:15 pm »
I want compute shaders too. I think SFML lacks both modern features and developer activity due to conservative ideology.  :-\  >:(

Tank

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1486
    • View Profile
    • Blog
    • Email
Re: Add Compute Shaders Support
« Reply #3 on: July 16, 2016, 02:09:05 pm »
ShqrdX, nobody stops you from using them, especially not SFML. I don't think binary1248 wanted to express that compute shaders have no use in SFML. But ask yourself where to put the limited developer resources into: Something that only a few people benefit from, or a larger audience?

Otherwise: Patch welcome, nobody prevents you from helping SFML. The sound of your demanding doesn't really fit in my opinion.

ShqrdX

  • Newbie
  • *
  • Posts: 12
    • View Profile
Re: Add Compute Shaders Support
« Reply #4 on: July 16, 2016, 03:31:12 pm »
Quote
Something that only a few people benefit from, or a larger audience?

And how do you know what larger audience wants ?

Compute shaders could be used for large number of graphics and physic simulations like particles, cloth etc...
Personally I want to create realistic flamethrower effect for my game...

Quote
But ask yourself where to put the limited developer resources into

Forgive me if Im wrong - but last commit on github was 29 days ago - enough time for making something good..

Quote
Patch welcome, nobody prevents you from helping SFML.

First - For helping I need to see a point of application.
Second -(about compute shaders) - It is not an easy target, SFML needs high quality code with good comments, I doubt that I can do it.
Third - If the idea have sceptical or negative view by SFML team members how much chance that someone will create it ?
« Last Edit: July 16, 2016, 04:26:08 pm by ShqrdX »

tony_kero

  • Newbie
  • *
  • Posts: 7
    • View Profile
Re: Add Compute Shaders Support
« Reply #5 on: July 16, 2016, 05:25:43 pm »
There is a high chance that i'll do a modified version of sf::Shader, because i love SFML and all of its resources/content, it will probably take time because actually i'm developing a big project (game) but i will probably try to use Compute Shaders in it, it will be a 2D game but i love algorithmic complexity so i will try to implement a nice procedural map generation, with chunks loading system etc, and to fast up things i want to use Compute Shaders(i know this is totally overkilled but anyway i will use these concepts in future projects).
My Game won't be open source (even if it is made of open-source only libraries and projects) but i will post to libraries authors all of my modifications if i do so.

Forgive my mistakes, i am french.

Tank

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1486
    • View Profile
    • Blog
    • Email
Re: Add Compute Shaders Support
« Reply #6 on: July 18, 2016, 08:04:10 am »
Quote
And how do you know what larger audience wants ?
I know that other things on the to-do list are better supported on people's hardware than compute shaders. That makes it, in that regard, lower priority than other features.

Quote
Forgive me if Im wrong - but last commit on github was 29 days ago - enough time for making something good..
You are wrong, and I forgive you.

To stay with your attitude: Enough time for you to learn to contribute to the project.

Quote
First - For helping I need to see a point of application.
You can contribute at any time.

Quote
Second -(about compute shaders) - It is not an easy target, SFML needs high quality code with good comments, I doubt that I can do it.
I guess you highly underestimate the process of adding such features. If you can't handle it yourself, also don't demand that within 29 days, "something good" can be made.

Quote
Third - If the idea have sceptical or negative view by SFML team members how much chance that someone will create it ?
With no single line has anyone of the team been sceptical or negative about the feature as-is. This forum is about feature requests of 2 sorts: 1) People ask for something, but don't plan to implement it themselves. 2) People want to discuss something they have or will implement(ed) themselves, to get it into SFML.

Both groups are alright, but when group 1 gets demanding, something is clearly wrong. We heard your way of arguing a million times already ("But everybody wants this", "I need this to make my flamethrower", "Other libraries also have it", "If SFML team doesn't implement it, people will move away from SFML" etc.). The point is: Especially(!) with your attitude of demanding things from people who don't owe you anything, you will even make things worse, not better.

Compute shaders are very useful, and they will find their way into SFML at some time, but just take a look at the huge list of things that are planned, and then re-think about computer shader's priority — which you can already use, just without SFML's syntactic sugar.

Next time you want something from other people without investing anything yourself, maybe try not to get personal in your first post. This is a pure personal advice.

jamesL

  • Full Member
  • ***
  • Posts: 124
    • View Profile
Re: Add Compute Shaders Support
« Reply #7 on: July 18, 2016, 10:38:13 am »
... but just take a look at the huge list of things that are planned..

is an actual "to do" list with priorities available ?
or were you just referring to this thread
 

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11039
    • View Profile
    • development blog
    • Email
AW: Add Compute Shaders Support
« Reply #8 on: July 18, 2016, 10:59:07 am »
Take a look at the open GitHib issues and pull requests: https://github.com/SFML/SFML/issues?utf8=✓&q=%20is%3Aopen%20

And then there are more things on the forum and in our heads that have not yet made it into a GitHib issue. ;)
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

Mr. X

  • Jr. Member
  • **
  • Posts: 80
    • View Profile
Re: Add Compute Shaders Support
« Reply #9 on: July 29, 2016, 02:15:32 pm »
Quote
First - For helping I need to see a point of application.
You can contribute at any time.
One can contribute at any time, but given that there are 34 open pull-requests, most of them "undecided" and quite old already indicates that the chances to get such contributions into SFML soon are quite low.
« Last Edit: July 29, 2016, 02:17:36 pm by Mr. X »

 

anything