Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
rabidrage

Combining brightmaps and PBR textures in GZDoom

Recommended Posts

So I downloaded HCBB.pk3 to add PBR textures to my mod.  My mod already has brightmaps, parked in a good old brightmaps folder inside my pk3.  When I add the normal/specular/materials/materials2/shaders folders and add the GLDefs to the lump I already have, the brightmaps stop working.  GZDoom tells me they're "not found" in the textures they correspond to.  I've tried adding the path to the same GLDefs that specify paths to normal, specular, etc.  It gives me the exact same message!  Nothing I do seems to work.  Where is the error?

Share this post


Link to post
Posted (edited)

So...in my search for an answer, I found the demo you've linked to.  And I narrowed the problem down to shaders.  Demo2 has no shaders, and the mod I'm trying to incorporate does.  However, I have found a brightmap mod that also applies shaders and *might* be compatible.  I haven't had much time to test it.

Edited by rabidrage

Share this post


Link to post

Also--the PBR pack I'm trying to use appears to rely heavily on shaders, which makes me wonder if this is ever all going to work.

 

 

 

 

 

Share this post


Link to post
Posted (edited)

This depends what version of GZDoom you're using and what shaders are being applied to the materials. IIRC, the engine uses shaders to apply the PBR maps, but is limited to having only two shaders for each material. Older versions of the engine used one shader for the PBR textures and an additional shader for the brightmap on top, which prevented any advanced shaders being added as well. If you try to add another shader to a PBR material with a brightmap, say a displacement or warping effect, then the older versions of the engine just fail to start and bomb out with the missing texture error unless you remove either the brightmap or shader. Newer versions will still load and run, but will simply omit the brightmaps from the applied materials in game. The latest builds (from 4.5 onwards, I think) they combined the brightmap functionality into the default shader, which means you can now use additional shaders with PBR materials and brightmaps, but the shader itself still needs to support loading the brightmaps natively.


After messing around and searching online for ages I finally managed to get the displacement map shader working with PBR materials and brightmaps, but I had to upgrade to GZDoom version 4.5+ first (for the new default shader brightmap support,) then hack the displacement shader manually to force it to load the brightmaps for materials that had a displacement shader applied.

Edited by RoadRunner12

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×