lfnetwork.com mark read register faq members calendar

Thread: Shader complicates amazing .efx file - help!
Thread Tools Display Modes
Post a new thread. Add a reply to this thread. Indicate all threads in this forum as read. Subscribe to this forum. RSS feed: this forum RSS feed: all forums
Old 09-13-2011, 11:27 AM   #1
FarbrorGnur
Rookie
 
FarbrorGnur's Avatar
 
Join Date: Aug 2011
Posts: 47
Shader complicates amazing .efx file - help!

Hey!

Ok, what I have done is that I've created a very nice .efx file, it looks just right in EffectsEd. It's small floating glowing white balls of light (SPRITES), and very many of them.

I have a .tga file with an alpha channel, and a shader that makes the black part get cut away.

Shader:

Code:
textures/kokiri/kokirisprite1
{
	q3map_nolightmap
	cull	disable
    {
        map textures/kokiri/kokirisprite1
        blendFunc GL_ONE GL_ONE_MINUS_SRC_ALPHA
        rgbGen lightingDiffuse
    }
}
NOTE: I don't truly, really know what cull disable and rgbGen lightingDiffuse does. BUT, I'm almost entirely sure the blendfunc is the problem.

THE PROBLEM:

The balls of light are black. They behave like they should, but they're black instead of white.
I tried some different blendfuncs, and many of them seems to remove all of the white floating balls except ONE. This one makes it the right color (white) and it floats alone, and disappears when I open my saber (reappears when I close it), juxtaposed to the black ones.

The shader above is the one generating black instead of white colors. If I change blendfunc to GL_ONE GL_ONE or any other I've tried, it takes away all but one and makes it the right color and buggy.


Any ideas, fellow shaders and.. and mapppers?

Correct but black orbs

Buggy orbs
FarbrorGnur is offline   you may: quote & reply,
Old 02-07-2012, 12:46 PM   #2
ds615
Rookie
 
ds615's Avatar
 
Join Date: Mar 2007
Posts: 42
Cull Disable makes it 2 sided, as in you can see it from either side.

Change your rbGen to rbgen vertex or rbgen identity, that should fix it for you.
ds615 is offline   you may: quote & reply,
Post a new thread. Add a reply to this thread. Indicate all threads in this forum as read. Subscribe to this forum. RSS feed: this forum RSS feed: all forums
Go Back   LucasForums > Network > JediKnight Series > Editing Central > JO Coding > Shader complicates amazing .efx file - help!

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 05:46 PM.

LFNetwork, LLC ©2002-2011 - All rights reserved.
Powered by vBulletin®
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.