Jump to content

Rend2 - A Modern Renderer


Recommended Posts

15 hours ago, Bad Dancer said:

Hi Somaz! Thank you! It worked.)

I want to make materials for many textures and improve textures. But it is very difficult to find a shader file for many textures. For example, I did not find a shader for this floor texture. https://drive.google.com/file/d/1ChIUp-V1WI0pfr2pFGmpjblOpL6GEFPE/view?usp=sharing 
Is there a way to quickly find the location of the shader for a texture?

Currently there's no easy way of finding the location of a shader. The surface you showed in the screenshot probably doesn't even use a shader, but just the texture. If that's the case, you can make use of the auto loading of material textures. Rend2 will automatically find normal maps for files with the suffix of "_n", normalHeight maps with "_nh", packed maps with "_rmo" and specular gloss maps with "_specgloss".

Means, if your material uses "textures/example/test.jpg" as a diffuse texture, rend2 will try to load "textures/example/test_n" as the corresponding normal map.

Bad Dancer likes this
Link to comment
  • 2 weeks later...

Ні SomaZ! Thank you very much!👍


Hello everyone! 👋🙂


Something strange with normalmaps on the model. Looks differently each time, and almost always incorrectly. (Random.)
I have to do a lot of restarts to make the texture look right.


Once the normalmap looked good: https://drive.google.com/drive/folders/1BgMsgThSjCQMi0gkMw6BMahNM6z1ywBQ
But after the vid_restart..: https://drive.google.com/drive/folders/14e227p6CbhhThkVdhbn1Hw7hz6_xlYDG

Normalmap - https://drive.google.com/drive/folders/107DZhCEB1mTgkpdaIGHp4T4NOHpaEfHm

Link to comment
  • 1 month later...

So I recently remembered to download OpenJK to my laptop (it was on my desktop lol), and I figured while I'm at it, lets dabble in Rend2.
Now I went ahead and made a test texture shader (and mtr file), shader loads in Radiant, but when I test in OJK, I get the infamous glowing bad shader.
I DID change the renderer in the command prompt "/cl_renderer rd-rend2; vid_restart", and it didnt give me any error.
I think I wrote my shader properly, but perhaps not.


        qer_editorimage textures/strombine/brick1_d

            map textures/strombine/brick1_d.tga
            rgbGen vertexLit
            normalHeightmap textures/strombine/brick1_local.tga
            specularmap textures/strombine/brick1_s.tga
	map $lightmap
	blendfunc gl_dst_color gl_zero

on the note of MTR files, do they go into a materials folder like in Q4, or do they go in the shaders folder?

Update, I fixed the errored shader issue (such a noob all the extra maps and stages lol ), and edited code to match.
But now, the walls with the shader texture are dark. I'm assuming this is due to the vertexlit tag in the first stage.
But also in the console it says that Stages 2 and 3 have no Image, even though the files exist in the folder, and are clearly listed in the shader.

Willemoes likes this

Check out some of my previous works:
JK Hub - [Editor: Zero Raven]

Link to comment
  • 8 months later...

I just released the first verison of rend2 in a very long time. I've been busy with fixing and reworking alot of things. The weather system is fully functional now as also alot of other things.

You can grab the latest release here:

- MSAA antialisaing cvar changed to r_ext_multisample which is the same as in the vanilla openjk renderer
- Added external hdr lightmap support
- Added autoload of images with following suffix "_specGloss", "_rmo" and "_orm"
- Realtime sun shadows won't flicker anymore when the player is moving around
- Some fixes regarding the HDR rendering pipeline (means rendering in hdr colors, but there's no HDR display support (and never will because OpenGL))
- Thanks to @Almightygirfor contributing a velvet shader (you can use it per shader stage, just add a 'cloth' to it (same as with glow or detail)) and fixes regarding pbr shading
- Added a shader stage keyword to "pull out" parallax mapped surfaces ('parallaxBias [0.0 ... 1.0]', you can easily test this with r_forceParallaxBias [0.0 ... 1.0])
- Added mikkTSpace for normal mapping (means baking normal maps in blender or substance will result in the same shading in rend2 now)
- Fixed rendering cloud layers
- Fixed wrong camera exposure on maps with sky portals
- Fixed alot of problems regarding fog
- Added flare rendering back
- Added most features back to surface sprites (only thing missing afaik is wind handling, swaying is implemented though)
- Speed up rendering dynamic lights with parallax occusion mapped surfaces by alot
- Added distortion rendering back (invicibility sphere, push/pull sphere)
- Added glass shattering back
- Added ghoul2 sabermarks back
- Added r_showTris 1 back
- Fixed a crash regarding md3 model caching
- Lots of other small things

I think that's all for now.

Some WIP pictures of my bespin duel remake with hdr lightmaps





Edited by SomaZ
Fixed spoiler tag
Link to comment

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
  • Create New...