Author
Message
TattieBoJangle
10
Years of Service
User Offline
Joined: 7th Jan 2014
Location: United Kingdom
Posted: 8th Jun 2014 23:58 Edited at: 9th Jun 2014 00:44
Hi guys anyone know what is going on with this i am using DXT5 for Transparent but the problem i have is it make what ever is behind it invisible lee had this with the chain fence but not sure how it was fixed.

As you can see below the DXT5 is making the DXT1 behind see through.











PC SPECS: Windows 8 Pro 64-bit, Intel I7 (PASSMARK 9529) 4GHz CPU, Asus R9 3GB GPU (PASSMARK 6858) 32GB DDR3 MEM (PASSMARK 2842)
tomjscott
User Banned
Posted: 9th Jun 2014 00:05
Did you set transparency in your fpe file?

System Specs: OS - Windows 7 Home Premium 64-bit SP1, CPU - AMD Phenom II X4 945, 3.0Ghz, RAM - 8Gb DDR3, GFX Card - 2048MB NVIDIA GeForce GT 640, FPSC-R Version - Beta 1.007
TattieBoJangle
10
Years of Service
User Offline
Joined: 7th Jan 2014
Location: United Kingdom
Posted: 9th Jun 2014 00:11 Edited at: 9th Jun 2014 00:44
tried changing the fpe a few times no change :/





PC SPECS: Windows 8 Pro 64-bit, Intel I7 (PASSMARK 9529) 4GHz CPU, Asus R9 3GB GPU (PASSMARK 6858) 32GB DDR3 MEM (PASSMARK 2842)
tomjscott
User Banned
Posted: 9th Jun 2014 00:35
I'm having this same problem with my shader effect, but that one I can understand because the engine doesn't know it's transparent and can't render it in the proper order, but your situation shouldn't have the problem. Very strange.

System Specs: OS - Windows 7 Home Premium 64-bit SP1, CPU - AMD Phenom II X4 945, 3.0Ghz, RAM - 8Gb DDR3, GFX Card - 2048MB NVIDIA GeForce GT 640, FPSC-R Version - Beta 1.007
TattieBoJangle
10
Years of Service
User Offline
Joined: 7th Jan 2014
Location: United Kingdom
Posted: 9th Jun 2014 00:47
Quote: " Very strange."


Yea it would be good for xray glasses





PC SPECS: Windows 8 Pro 64-bit, Intel I7 (PASSMARK 9529) 4GHz CPU, Asus R9 3GB GPU (PASSMARK 6858) 32GB DDR3 MEM (PASSMARK 2842)
rolfy
18
Years of Service
User Offline
Joined: 23rd Jun 2006
Location:
Posted: 9th Jun 2014 00:54 Edited at: 9th Jun 2014 00:59
This is an issue I have mentioned several times to no avail, to fix it for now remove the fence from the map, save,close and reopen Reloaded, put your fence in the map so it comes into the editor last.



It's to do with draw order and nothing seems to fix it except the above, setting transparency to '2' in the fpe is supposed to but simply doesn't.The problem may be solved on simple maps using the above but it's not easily fixed if your going to have a number of transparencies in your level and trying to get the order correct for this. I dread the idea of buildings with transparent windows.

You will see this if you try to do anything with the Asylum from the Horror pack.



It gets even worse when trying to set an order for different transparent models which may cull each other.

A funny thing happened on the way to the forum...
TattieBoJangle
10
Years of Service
User Offline
Joined: 7th Jan 2014
Location: United Kingdom
Posted: 9th Jun 2014 01:07
Hmm this is not good i do have a problem with windows also where you look out and any models outside are invisible but the shadows remain i will just set it to DXT1 until this is fixed

Thanks for the info





PC SPECS: Windows 8 Pro 64-bit, Intel I7 (PASSMARK 9529) 4GHz CPU, Asus R9 3GB GPU (PASSMARK 6858) 32GB DDR3 MEM (PASSMARK 2842)
tomjscott
User Banned
Posted: 9th Jun 2014 01:44
Quote: "It's to do with draw order and nothing seems to fix it except the above,"


Yep, I reported it to them with my shader and told them it was a rendering order issue. I didn't know transparency = 2 was supposed to solve it though. Unfortunately, no transparency setting would work in my case because it also tries to apply transparency to my shader and then screws up the already working transparency. Fortunately, the one place I really need my effect is where it happens to be working at the moment.

System Specs: OS - Windows 7 Home Premium 64-bit SP1, CPU - AMD Phenom II X4 945, 3.0Ghz, RAM - 8Gb DDR3, GFX Card - 2048MB NVIDIA GeForce GT 640, FPSC-R Version - Beta 1.007
rolfy
18
Years of Service
User Offline
Joined: 23rd Jun 2006
Location:
Posted: 9th Jun 2014 01:57 Edited at: 9th Jun 2014 02:17
There are only two settings at present for transparency in entity fpe '1' and '2', in Classic there were five and they were to do with varying full or semi-transparency, draw order and culling, the fpe setting does not apply transparency itself to an object. Only the texture alpha does this.



In simple terms it is not a 'range', it is a mode.

A funny thing happened on the way to the forum...
tomjscott
User Banned
Posted: 9th Jun 2014 03:49
Quote: "the fpe setting does not apply transparency itself to an object"


It does, in fact, do something. Because when I set transparency on my shader effect, it really mangled it up. If it was just a draw order thing then it wouldn't have messed it up. I wish it just honored draw order with the effect because then my effect would work properly.

System Specs: OS - Windows 7 Home Premium 64-bit SP1, CPU - AMD Phenom II X4 945, 3.0Ghz, RAM - 8Gb DDR3, GFX Card - 2048MB NVIDIA GeForce GT 640, FPSC-R Version - Beta 1.007
rolfy
18
Years of Service
User Offline
Joined: 23rd Jun 2006
Location:
Posted: 9th Jun 2014 04:27 Edited at: 9th Jun 2014 04:59
Quote: "If it was just a draw order thing then it wouldn't have messed it up."
Take the info or leave it.



Did a quick test using transparency settings 1,2,4,8,10,50 it had no effect whatsoever on the transparency of the entity itself



I have no idea what you mean by applying this setting to your 'shader effect' since the mode is set in the .fpe. There was a way to script transparency in Classic using alphafadeequal to alpha fade entities but this would not have trashed your transparency as you describe.



So it may be a bug but it's nothing to do with the mode setting that I can reproduce.

A funny thing happened on the way to the forum...
tomjscott
User Banned
Posted: 9th Jun 2014 05:07
@rolfy, my situation is different. I'm giving you accurate information so please just trust me. There is a difference between a simple entity with a transparent texture and one that has a shader effect applied with Alpha Blending. In my case, it seriously
rolfy
18
Years of Service
User Offline
Joined: 23rd Jun 2006
Location:
Posted: 9th Jun 2014 05:28 Edited at: 9th Jun 2014 07:01
Quote: "There is a difference between a simple entity with a transparent texture and one that has a shader effect applied with Alpha Blending."
I don't know which of us is confused here but unless you think I am not using shaders you will need to explain the difference to me.

Quote: "In my case, it seriously messes up the effect when the fpe transparency setting is set."
Nor do you say what your setting it to.



In the shader:

AlphaBlendEnable = TRUE;

AlphaTestEnable = true;



This is fairly basic stuff. If there is some other alpha blending your referring to in your custom shader then you need to point me in the right direction. Maybe then it might be easier to pinpoint why setting these modes are causing you issues, I told you its not a range it's a mode and only two of these at this point no other setting will have any effect and even these should not be affecting your alpha.



I am not saying your not having issues but I think your on the wrong track as to the cause. My info is correct, if you think it is wrong then that's fine but arguing about it won't help you nor will it help others understand what the settings actually are. Yourself and others in another thread seem to think it's a range (0-100) for transparency of your entity and you believe it somehow tries to apply transparency to your effect, it's doesn't, I just inform what it is actually supposed to do, that's all



I am telling you there are only two mode settings at present, it makes no difference if your setting it to anything else and it causes issues. You shouldn't be using any others in the first place, so whats the point of complaining about it if it works as it should for you using 1-2?



The issue I have here is the same issue as the OP and that's what I am addressing not a non issue with mode settings that are not supported..or even exist.

Transparency culling and draw order isn't working as it should, I have even found myself struggling with object hierarchy order in an attempt at fixing at the modeling stage and it's been no fun, it's even less fun when you get no response to questions on it.

A funny thing happened on the way to the forum...
tomjscott
User Banned
Posted: 9th Jun 2014 16:05
@rolfy, you just aren't getting what I'm saying at all. I'll just break it down to the following since you are confused.

1. My shader effect works fine except for being rendered out of order, which causes the x-ray effect for objects behind it (in some
rolfy
18
Years of Service
User Offline
Joined: 23rd Jun 2006
Location:
Posted: 9th Jun 2014 16:39 Edited at: 9th Jun 2014 16:44
Still got no idea what shader your using to animate the texture, Atlas walk? Its certainly not a stock shader for Reloaded.



Perhaps you need to change the shader rather than worry about the setting trashing it, the setting is "supposed" to work as I say.



All the same all the info your going to get from Lee is that '0' is no transparency (which we both know is incorrect) and '1' which is transparency, the rest he says you can work out for yourself...?



So since your using a non stock shader and there will be no info from TGC, your on your own with this one.

A funny thing happened on the way to the forum...
tomjscott
User Banned
Posted: 9th Jun 2014 16:43
@rolfy, it's a custom shader effect. I'd love to change the shader if it could magically tell the engine what order to draw it in, but as you must certainly know that that is impossible. lol. I tried transparency = 1 as well and that doesn't help. I have
rolfy
18
Years of Service
User Offline
Joined: 23rd Jun 2006
Location:
Posted: 9th Jun 2014 16:46 Edited at: 9th Jun 2014 16:48
There are settings for cullmode in the shader, I have tried changing cw to ccw etc (which are really setting for back or front face culling) but it didn't help.

A funny thing happened on the way to the forum...
tomjscott
User Banned
Posted: 9th Jun 2014 16:47
I'll tell you this much. Transparency = 1 makes it so there is almost a battle going on between what it should be doing and failing. So, it sort of helps, but the x-ray effect is still seen. Not quite sure why in the world it could manage to sort of help, but then still be drawing out of order. It's like some pixels being drawn get done right and others not and I don't see how that's possible. Very strange indeed.

System Specs: OS - Windows 7 Home Premium 64-bit SP1, CPU - AMD Phenom II X4 945, 3.0Ghz, RAM - 8Gb DDR3, GFX Card - 2048MB NVIDIA GeForce GT 640, FPSC-R Version - Beta 1.007
tomjscott
User Banned
Posted: 9th Jun 2014 17:03 Edited at: 9th Jun 2014 17:03
As I look at my issue again, I'm starting to think that maybe it isn't an engine issue after all, but just the shader. So, I apologize for insisting that I was right. I'm taking a closer look at the code to see what might be wrong on my end. I believe setting transparency = 1 should solve my issue if I can figure out why my shader is wonky. Thanks for the discourse, rolfy, since that's what sparked me to take a closer look at this.

System Specs: OS - Windows 7 Home Premium 64-bit SP1, CPU - AMD Phenom II X4 945, 3.0Ghz, RAM - 8Gb DDR3, GFX Card - 2048MB NVIDIA GeForce GT 640, FPSC-R Version - Beta 1.007
rolfy
18
Years of Service
User Offline
Joined: 23rd Jun 2006
Location:
Posted: 9th Jun 2014 17:07
No worries, I responded to your PM

A funny thing happened on the way to the forum...
bond1
19
Years of Service
User Offline
Joined: 27th Oct 2005
Location: Knoxville, TN
Posted: 9th Jun 2014 18:37 Edited at: 9th Jun 2014 18:40
For custom shaders, you can hard code the transparency and bypass the engine to fix draw order problems (a directx limitation).





For simple "cutout" transparency that does not require semi-transparency, use alpha testing. This is draw order independent:





Alphatestenable=TRUE;

Alphablendenable=FALSE;

alphafunc=greater;

//also specify a cutoff value for the edges

alpharef=128







For semi-transparency, use alpha blending. For most particle type effects (smoke,fire, etc.) you can bypass the draw order problem by disabling Z-writing.





Alphatestenable=FALSE;

Alphablendenable=TRUE;

ZEnable=true;

ZWriteEnable=false;





Hope this helps!

SPECS: Intel Corei7 3770k, Nvidia GTX780, 16GB RAM, Win7 Pro

kW-Xport for 3ds Max:http://mjblosser.com/kw-x-port-for-3ds-max/
Scene Commander
Support Manager
16
Years of Service
User Offline
Joined: 3rd May 2008
Location:
Posted: 9th Jun 2014 18:39
@tomjscott

Sent you an email.

i7-4770s 3.10ghz - Geforce GTX 650ti
tomjscott
User Banned
Posted: 9th Jun 2014 18:42
@bond1, thanks for the info. I tried a lot of combinations of those parameters, including zenable and zwriteenable and they did not work for my fire effect. I'm not sure I tried the exact combination you suggest though and it's worth a look.

However,
bond1
19
Years of Service
User Offline
Joined: 27th Oct 2005
Location: Knoxville, TN
Posted: 9th Jun 2014 18:47
If you're using a custom shader, I would suggest against using TGC's advice here, and leave the fpe setting empty. Using a shader, you're talking directly to the GPU. No sense it letting the engine try and set one setting while you're shader is setting another. Could be causing a conflict.

SPECS: Intel Corei7 3770k, Nvidia GTX780, 16GB RAM, Win7 Pro

kW-Xport for 3ds Max:http://mjblosser.com/kw-x-port-for-3ds-max/
tomjscott
User Banned
Posted: 9th Jun 2014 18:56
OK, everyone, here is the definitive answer I got from Dave (Scene Commander) on this.


Transparency settings are hard coded into DBP and don't have a logical
math based setup.

The modes are:

0 - draw first no alpha
1 - draw first with alpha masking
2 and 3 - draw second which overlaps solid geometry
4 - draw second alpha test (only render beyond 0x000000CF alpha values)
5 - water line object (seperates depth sort automatically)
6 - combination of 3 and 4 (second phase render with alpha blend AND
alpha test, used for fading LOD leaves)


So, using transparency = 1 does, in fact, apply alpha masking in the engine itself. It seems I was right on this after all. . Anyway, for my personal fire effect issue, 5 is the correct setting. For others, the list of options above should help.

System Specs: OS - Windows 7 Home Premium 64-bit SP1, CPU - AMD Phenom II X4 945, 3.0Ghz, RAM - 8Gb DDR3, GFX Card - 2048MB NVIDIA GeForce GT 640, FPSC-R Version - Beta 1.007
rolfy
18
Years of Service
User Offline
Joined: 23rd Jun 2006
Location:
Posted: 9th Jun 2014 19:32 Edited at: 9th Jun 2014 19:33
I had tried the other modes in the past and found it didn't help, it had only been mentioned that '2' could be used. So it's my turn to apologise, if I had known and told you to try them it would have saved you a lot of grief



And thanks for the additional info Mark.

A funny thing happened on the way to the forum...
tomjscott
User Banned
Posted: 9th Jun 2014 19:35
Quote: "if I had known and told you to try them it would have saved you a lot of grief"


No problem. I'm just happy it's finally going to work. That just opened up a whole playground for me to work in with shaders. Now, If I can just get caught up on my entry, it'll be something really special.

System Specs: OS - Windows 7 Home Premium 64-bit SP1, CPU - AMD Phenom II X4 945, 3.0Ghz, RAM - 8Gb DDR3, GFX Card - 2048MB NVIDIA GeForce GT 640, FPSC-R Version - Beta 1.007
tomjscott
User Banned
Posted: 9th Jun 2014 21:26
I spoke too soon. transparency = 5 didn't work for me at all. I also tried the following:

Alphatestenable=FALSE;
Alphablendenable=TRUE;
ZEnable=true;
ZWriteEnable=false;

That simply causes the effect to always render behind eveyrthing. So, that's a no go as well. I'm open to other suggestions, but it seems like this just isn't going to work right now.

System Specs: OS - Windows 7 Home Premium 64-bit SP1, CPU - AMD Phenom II X4 945, 3.0Ghz, RAM - 8Gb DDR3, GFX Card - 2048MB NVIDIA GeForce GT 640, FPSC-R Version - Beta 1.007
bond1
19
Years of Service
User Offline
Joined: 27th Oct 2005
Location: Knoxville, TN
Posted: 9th Jun 2014 21:45 Edited at: 9th Jun 2014 21:46
Could you explain what you mean by `always render behind everything'? Or better yet post a screenshot?



I use these settings all the time for rendering fire sprites very similar to the one you've shown. Did you clear out any transparency references in the fpe file so it doesn't conflict with your renderstates in the shader?





I have a feeling I'd need to see your shader code and textures to pinpoint it exactly, to see exactly where and how your alpha is getting drawn.

SPECS: Intel Corei7 3770k, Nvidia GTX780, 16GB RAM, Win7 Pro

kW-Xport for 3ds Max:http://mjblosser.com/kw-x-port-for-3ds-max/
tomjscott
User Banned
Posted: 9th Jun 2014 22:02 Edited at: 9th Jun 2014 22:36
Here is how it looks.



http://youtu.be/rx13wnDFW1M

System Specs: OS - Windows 7 Home Premium 64-bit SP1, CPU - AMD Phenom II X4 945, 3.0Ghz, RAM - 8Gb DDR3, GFX Card - 2048MB NVIDIA GeForce GT 640, FPSC-R Version - Beta 1.007

Login to post a reply

Server time is: 2024-11-24 04:13:11
Your offset time is: 2024-11-24 04:13:11