ZScript function for checking if pp shaders are supported

Remember, just because you request it, that doesn't mean you'll get it.

Moderator: GZDoom Developers

ZScript function for checking if pp shaders are supported

Postby Marisa Kirisame » Tue May 08, 2018 11:35 am

Rather than commit the long-forbidden crime of attempting to detect renderers, it would be preferable to have something on the ui side for checking if shaders can be used since, at the moment, software renderers can't do pp shaders (despite the fact they're still using an accelerated framebuffer).

I'm not familiar with the rendering side of the engine, so I can't do much myself for this.
User avatar
Marisa Kirisame
ZScript Magician
 
 
 
Joined: 08 Feb 2008
Location: Vigo, Galicia
Discord: Marisa Kirisame#4689
Twitch ID: magusmarisa
Github ID: OrdinaryMagician
Operating System: Other Linux 64-bit
Graphics Processor: nVidia with Vulkan support

Re: ZScript function for checking if pp shaders are supporte

Postby Xaser » Tue May 08, 2018 11:52 am

Related post of mine -- I'll quote the relevant bit so it's in context:

Xaser wrote:What we could really use here is a new feature: a set of MAPINFO flags that declare "I require feature 'x'", e.g. sloped 3D Floors or Truecolor, and have the engine output a warning if a user starts up the map with a renderer that doesn't support one of the declared features. This doesn't expose anything to ZScript, and since it's detecting the feature, not the renderer, it's future-proof -- e.g. if the Carmack renderer magically gets sloped 3D floors, it's marked as supported internally and the warning goes away for maps that declare it.


Works a bit differently since there's no ZScript exposure, and I'm not sure about your specific use case enough to know if this fits, but there it is.
User avatar
Xaser
anarchivist
 
 
 
Joined: 20 Jul 2003

Re: ZScript function for checking if pp shaders are supporte

Postby Marisa Kirisame » Tue May 08, 2018 11:56 am

Well my specific use case is more about UI drawing (where one could fall back to something else if shaders aren't available)
User avatar
Marisa Kirisame
ZScript Magician
 
 
 
Joined: 08 Feb 2008
Location: Vigo, Galicia
Discord: Marisa Kirisame#4689
Twitch ID: magusmarisa
Github ID: OrdinaryMagician
Operating System: Other Linux 64-bit
Graphics Processor: nVidia with Vulkan support

Re: ZScript function for checking if pp shaders are supporte

Postby Rachael » Tue May 08, 2018 11:57 am

Seeing as how users can get annoying with "warning messages" I really would rather just let the engine handle the warning and leave it at that.

Also, seeing as how GZDoom will in the sooner-than-distant-future be requiring OpenGL 3.3 (which has user shader support) and that software mode will be getting shaders anyhow, this will not even be needed in the long run.
User avatar
Rachael
Webmaster
 
Joined: 13 Jan 2004
Discord: Rachael#3767
Twitch ID: madamerachelle
Github ID: madame-rachelle

Re: ZScript function for checking if pp shaders are supporte

Postby Marisa Kirisame » Tue May 08, 2018 12:00 pm

Rachael wrote:and that software mode will be getting shaders anyhow


I was waiting for an official confirmation of this.
User avatar
Marisa Kirisame
ZScript Magician
 
 
 
Joined: 08 Feb 2008
Location: Vigo, Galicia
Discord: Marisa Kirisame#4689
Twitch ID: magusmarisa
Github ID: OrdinaryMagician
Operating System: Other Linux 64-bit
Graphics Processor: nVidia with Vulkan support

Re: ZScript function for checking if pp shaders are supporte

Postby Rachael » Tue May 08, 2018 12:02 pm

I know it's been planned - I think it would reduce a lot of code duplication if at least several of the "software" and OpenGL-specific shaders were merged together, anyhow. IMO it should all go through a single shader path.
User avatar
Rachael
Webmaster
 
Joined: 13 Jan 2004
Discord: Rachael#3767
Twitch ID: madamerachelle
Github ID: madame-rachelle


Return to Feature Suggestions

Who is online

Users browsing this forum: No registered users and 2 guests