Jump to content

Rend2 beta


Rooxon

Recommended Posts

Posted

I think I asked this before, though I can't find the conversation/topic. Where can I download a rend2 beta to test out? I remember I was playing with it once already, I think. Also I'm interested in what shader options I have as a mod maker regarding weapons and how to utilize them in rend2, but I can talk about this with people on Skype.

Posted

You can get the current version at https://github.com/JACoders/OpenJK/tree/rend2 (download as zip).

The way I remember it, you put rend2 specific shaders in .mtr files in your /shaders folder, which will overwrite shaders with the same name for vanilla. cl_renderer must be set to rend2. @@Xycaleth can give you some more useful tips and commands, or you could look through the rend2 thread for some of them.. I can't remember them at the moment.

 

An example shader for something I have in my base folder:

 

 

 

textures/a_rend2map/bricks3
{
	qer_editorimage	textures/a_rend2map/bricks3
	{
		map textures/a_rend2map/bricks3
	}
	{
		stage normalparallaxmap
		map textures/a_nmaps/bricks3_nmap
	}
	{
		map $lightmap
		blendFunc filter
	}
}

textures/a_rend2map/streetrocks
{
	qer_editorimage	textures/a_rend2map/streetrocks
	{
		map textures/a_rend2map/streetrocks
	}
	{
		stage normalmap
		map textures/a_nmaps/streetrocks_nmap
	}
	{
		map $lightmap
		blendFunc filter
	}
} 

 

 

 

EDIT: Forgot that the Github links to the project, not a pre-built dll!

Posted

Would be good if this could be moved to the OpenJK forum :) *hint hint at mods* Preferably with a redirect from this forum so OP can still find it.

 

The easiest way to get rend2 up and running is by using a prebuilt DLL. Steps are as follows:

  1. Download the VC++ 2013 Redistributable (make sure you choose x86): http://www.microsoft.com/en-gb/download/details.aspx?id=40784
  2. Download the rend2 DLL: https://dl.dropboxusercontent.com/u/874909/rd-rend2_x86.zip
  3. Copy the DLL into your GameData/ folder.
  4. Start up OpenJK.
  5. In the console, type "/cl_renderer rd-rend2; vid_restart"

If everything worked, it should all look the same in the main menu. Type "/cl_renderer" in the console again to check that rend2 is running.

 

Commands and cvars can be found here: https://github.com/ioquake/ioq3/blob/c04d05fd8f64b62201b100d410da52e1ab3eec17/opengl2-readme.txt

 

rend2 is based on the one in ioq3 so the readme is fairly accurate.

Tempust85, Rooxon, Keyten and 1 other like this
Posted

@@Rooxon PM'd me for some help but I thought I'd copy part of my message here in case it helps anyone else:
 
The bit I didn't explain is the new shaders. I can give a quick overview here. I'll post it in the topic as well so others can read it. Rend2 supports another shader file called a .mtr file (short for material). Both the .shader files and .mtr files can use the new shader keywords, but if a .shader file and a .mtr file share the same name, then the .mtr file will be used. This let's you keep compatibility with the base renderer. For example, if you have rooxon.shader and rooxon.mtr, then rooxon.mtr will be loaded, and rooxon.shader will be ignored.
 
Since rend2 supports normal maps, specular maps, etc, you need a way to tell the game that your texture uses these. Take a look at the example below:

textures/rooxon/head
{
  q3map_nolightmap
  {
    stage diffuseMap // This line isn't strictly necessary. The stage is "diffuseMap" if you don't specify it.
    map textures/rooxon/head_d
    rgbgen lightingDiffuseEntity
  }
  {
    stage normalMap
    map textures/rooxon/head_n
  }
  {
    stage specularMap
    map textures/rooxon/head_s
  }
}

This is a really basic example, but is usually all you will need for a character model. There's some more fancy stuff you can do with the 'shininess' of the material but that is all you should need for now.
 
One thing to note is that the new keywords are very much likely to change at some point in the future as rend2 progresses a bit further.

Rooxon and Scerendo like this
Posted

That's exactly what I needed, the .dll and the shaders explanation. I'll check everything else in the readme. Thank you very much for your help, all of you!

Posted

Allright, in any case, I will use this thread for any future questions I may have regarding mod creations for Rend2.

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...