Page 1 of 1

GtkRadiant: in-editor shader problems

Posted: Fri Jul 12, 2013 2:17 pm
by TheCatProblem
Hello,

I've just started using GtkRadiant 1.5 (I'm pandering to my own nostalgia and messing around with cutscenes in Elite Force) and I've noticed that it appears to have a couple of problems related to the display of certain shaders.

The qer_trans property appears to be ignored, so all the trigger, clip, glass, etc. textures are opaque rather than translucent. This isn't the end of the world but makes it difficult to get a good sense of the level geometry while positioning clips and triggers.

Here's a shader (for the trigger texture) that has this problem:

Code: Select all

textures/common/trigger
{
    qer_nocarve
    qer_trans 0.5
    surfaceparm nodraw
    surfaceparm nolightmap
}
A second issue I've observed is that certain textures don't show up in the editor (the "shader not found" texture is shown for them) but appear in the game after the map is compiled. This problem appears to be limited to shaders for which the shader and texture names are not the same. For example, the shader shown below is (correctly) listed as "liftlights_light" in the GtkRadiant texture pane, but the texture shown for it is "shader not found" rather than "liftlights.tga" (as specified by the qer_editorimage directive). There's a bug report related to qer_editorimage from 2001 that might be relevant to this, but I'd be surprised if this same bug hadn't been fixed by the final release of GtkRadiant 1.5.

Example shader (shows up as "liftlights_light" with "shader not found" texture in editor):

Code: Select all

textures/voyager/liftlights_light
{
    qer_editorimage textures/voyager/liftlights.tga
    {
        map textures/voyager/liftlight_gradiant.tga
        blendFunc GL_ONE GL_ZERO
        rgbGen identity
        tcMod scroll 0 -2
    }
    {
        map textures/voyager/liftlights.tga
        blendFunc GL_ONE GL_SRC_ALPHA
        rgbGen identity
    }
    {
        map $lightmap
        blendFunc GL_DST_COLOR GL_ZERO
        rgbGen identity
    }
}
I'd appreciate any suggestions for resolving these issues; they're not the end of the world, but they're kind of annoying!

Re: GtkRadiant: in-editor shader problems

Posted: Sat Jul 13, 2013 8:23 am
by D-Meat
Have you added your shader to the shaderlist ? I don't remember if this is revelant in this case ...

Re: GtkRadiant: in-editor shader problems

Posted: Sat Jul 13, 2013 1:05 pm
by TheCatProblem
These are actually shaders that came with the game/editor, but I checked the shaderlist (and GtkRadiant's default-shaderlist file for Elite Force) and all the shader directories are listed. (The problematic shaders are listed in GtkRadiant, they just aren't displayed correctly.)

I came across a post from 2009 in which someone offers an altered version of stvef.game for GtkRadiant 1.5 to correct the exact two problems I've encountered (namely, the qer_trans and qer_editorimage directives being ignored). Unfortunately, the link to the modified version of stvef.game is dead.

Interestingly, stvef.game is just a simple XML file (it can be viewed in the GtkRadiant gamepack repository here), but none of the properties in it appear immediately relevant to this problem. I've compared it with another .game file, and there are differences, but I'm not sufficiently familiar with the Radiant family of editors to know if any of these are significant.

Re: GtkRadiant: in-editor shader problems

Posted: Sat Jul 13, 2013 2:47 pm
by obsidian
Have you been able to replicate this issue with GtkRadiant 1.4? I'd ask you to try 1.6 as well, but STVEF isn't officially supported yet.

If it only occurs with 1.5, it may be some weird program bug, if it occurs with both versions, it'll be an issue with the game pack files. If the latter, it might be something that can be fixed.

Re: GtkRadiant: in-editor shader problems

Posted: Sun Jul 14, 2013 2:34 pm
by TheCatProblem
Thanks for the suggestion; I'll try GtkRadiant 1.4 to see if the same issue occurs. I suspect it may be an issue with the game pack, however, since that "Chris Parker" fellow was apparently able to fix the problem (for GtkRad 1.5) simply by editing stvef.game.

Re: GtkRadiant: in-editor shader problems

Posted: Sun Jul 14, 2013 3:29 pm
by obsidian
Well, I can take a look at gamepack issues and update it if required, I just need to know whether the issue is indeed caused by the gamepack or if 1.5 is just buggy.

You can also give NetRadiant a try as well, it's based off of 1.5 and maybe they fixed it.

Let me know how it works out for you.

Re: GtkRadiant: in-editor shader problems

Posted: Tue Jul 16, 2013 9:30 pm
by TheCatProblem
Okay, I tried GtkRadiant 1.4 and the qer_trans and qer_editorimage directives are interpreted correctly (i.e., triggers, clips, etc. are translucent and textures specified using qer_editorimage are shown in the editor).

Since this appears to be a bug in GtkRadiant 1.5, is it worth filing an issue on the GtkRadiant GitHub page or will it just be ignored since it's (presumably) not a problem with 1.6?

Re: GtkRadiant: in-editor shader problems

Posted: Wed Jul 17, 2013 4:08 am
by obsidian
GtkRadiant 1.5 isn't supported anymore, none of the developers for that branch are working on it anymore.

NetRadiant is a continuation of the 1.5 branch, so if NetRadiant has the same bug, you can report it to them.

Otherwise, if you know of a number of people who may map for STVEF and would like to work with the GtkRadiant 1.6 team in adding support for it, all we need are willing volunteers. Support probably isn't too hard since the gamepacks are fairly intact, but we'll need a lot of people to test and maybe contribute a few bits of code.

Re: GtkRadiant: in-editor shader problems

Posted: Thu Jul 18, 2013 7:21 pm
by TheCatProblem
I don't personally know anyone else who's interested in modding Elite Force, but I'd be willing to test the STVEF gamepack with GtkRadiant 1.6 (according to the gamepack repository, it's recently been updated to use the new 1.6 gamepack directory structure, so perhaps I could just go ahead and try it). I might be able to contribute some code as well if it's necessary to do so in order to get GtkRadiant 1.6 working with EF (although it appears that support may already have been added).

What's the best place to discuss this further (e.g., if I try the STVEF gamepack with 1.6 and find bugs)?

Re: GtkRadiant: in-editor shader problems

Posted: Fri Jul 19, 2013 3:03 am
by obsidian
Oh derp :dork:... I forgot about that most recent update, yes ETVEF will be supported with the upcoming release of GtkRadiant 1.6.4.

I don't think we have the latest compiled binaries for that ETVEF update yet, if you are able you can compile it yourself, or just wait a week or two for TTimo to issue a new development build to test with.

New development builds of GtkRadiant will be posted on the IRC channel topic title, the latest one dated 20130707.

For discussions, you can visit the official GtkRadiant IRC channel:
http://webchat.quakenet.org/?channels=radiant

If you have a bug you would like to report, just create a new issue on the GtkRadiant issue tracker with whatever relevant information you can provide.
https://github.com/TTimo/GtkRadiant/issues

Finally, you can also post here, people are quite friendly and helpful on this part of the forum. Just be wary of some of the folks in General Discussions and The Void, they're old and cranky. :)

Re: GtkRadiant: in-editor shader problems

Posted: Fri Jul 19, 2013 5:49 pm
by TheCatProblem
I'll probably just wait for the next development build to be released and then try it with the Elite Force gamepack.

Thanks for all your help, Obsidian.