3rd Party Models/Media Chat / Partial Transparency Mapping - Anyway to Accomplish?

Author
Message
pianodavy
11
Years of Service
User Offline
Joined: 5th Nov 2013
Location: United States
Posted: 4th Dec 2013 05:32
I made 3 different versions of a texture map. Each version had sections with walls completely opaque mixed with smaller sections of windows which I gave transparencies to. One was 40% transparency, another 50% and the last 60%. The colors showed up fine in the 2 smaller percentages but no shadowy semi transparency at all - simply solid. The 60% model had it's transparency section completely invisible. I don't want to make the entire model transparent - just the polys that I textured with a transparency - and even then, I only want those sections to be partially transparent. I saved them as a .png and converted them to .dds. Any ideas? Should I try 51% or 52% or will this just make it invisible as it did at 60%? I'm thinking there is probably some code in the model needed, am I right?

All you need is love....so let me have your burger.
Dosedmonkey
10
Years of Service
User Offline
Joined: 26th Nov 2013
Location:
Posted: 4th Dec 2013 09:19
Are you doing the transparency by means of Alpha channel? Not sure if this is how its done in FPSCR, but might be worth trying.
PM
pianodavy
11
Years of Service
User Offline
Joined: 5th Nov 2013
Location: United States
Posted: 4th Dec 2013 12:02
Well, the problem is, I am not wanting FPSCR to render the entire model transparent, only a material group of it. I mapped the group as transparent in my paint program and it TrueSpace renders that specific section of the model as partially transparent (as it should), but FPSCR only seems to render my map in that same material group as 100% transparent in one version or completely opaque in the other 2 versions. maybe i need to try something other than .png before I convert to .dds? Maybe targa? This is really frustrating!

All you need is love....so let me have your burger.
Dosedmonkey
10
Years of Service
User Offline
Joined: 26th Nov 2013
Location:
Posted: 5th Dec 2013 06:53 Edited at: 5th Dec 2013 07:15
Okay so year, opened up the textures on a couple of FPSCR partial transparent objects, and they are done here the same as a lot of other game engines. Where you must change the Alpha Channel, making it half way between black and white colour will modify how transparent a surface is.







Here is the Alpha channel from the Plastic Red Crate which is default box type in FPSCR. Notice the white is 0% transparency, and the black is 100% transparency. If you modify it so you have the grey colour exactly half way between fully black and fully white, you'll get 50% transparency, then depending on RGB channel, it will appear a certain semi transparent colour.



I believe however, once the engine is further a long there will be materials you can enter, such as glass, but not sure how they work exactly, never gone more advanced then this before.



Update: Been trying this out, I can't get partial transparency, only complete. Not sure if I am exporting my .dds wrongly or if the engine just doesn't support it.
PM
pianodavy
11
Years of Service
User Offline
Joined: 5th Nov 2013
Location: United States
Posted: 5th Dec 2013 12:47
You are experiencing exactly the same anomaly as I have. I am confused as to the reason why partial transparencies would either be so difficult to accomplish or, as is suggested, is not available on this engine at this time. I know I can make a single model that can be totally transparent to some percentage - or totally opaque with FPSCR - but there seems to be no way to have maps on a single object that will make parts of the object partially transparent mixed with parts totally opaque. The reason this is confusing to me is because so many other programs have accomplished this technique years ago - am I hoping for too much? Honestly, I understand the program is in beta, but if this sort of programming is beyond the reach of it's developers, it almost seems to me that the future of FPSCR has a bleak potential for artists who wish to create a wide diversity of appealing objects - which in turn also limits the program for anything much more than what appears to be - a dated shoot-em-up game. Maybe the program's name is prophetic, I certainly hope not. On the other hand, if there is a way to sort out this problem, it would behoove the development team to expand on it's functionality through both it's code and some simple and easily available tutorials so that the artists who wish to advance it's development could truly present some examples of advanced presentations to the thousands and thousands of potential customers in the marketplace. The question is simple - do beta versions of FPSCR really need to be so deplete of common place graphic tools?

All you need is love....so let me have your burger.
Green Gandalf
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Location: Cornwall UK
Posted: 5th Dec 2013 13:33 Edited at: 5th Dec 2013 15:59
Partial transparency is always an awkward one because you need to have fine control over render order - i.e. the partially transparent objects need to be drawn after other things behind them, including other partially transparent objects. An all or nothing system is much easier to implement since you can render in the usual way and just use clipping to stop the transparent pixels being drawn (as used in the default entity shader I believe).



You might be able to work around this limitation by having a "cloudy" black and white alpha map so you get a mixture of fully opaque and fully transparent pixels. In some situations, e.g. dirty windows, that could be quite realistic anyway.



Edit The problem with what I've just said is that the clean bits of glass should reflect - and clipping doesn't allow that.



If you're interested in pursuing that idea I'll see if I can put together a simple demo object.





Powered by Free Banners
HarryWever
3D Media Maker
14
Years of Service
User Offline
Joined: 14th Jan 2010
Location: below Sea level
Posted: 5th Dec 2013 23:13
i am very interested.

I love to see a demo object..



Gr
PM
The Rev
20
Years of Service
User Offline
Joined: 26th Apr 2004
Location: Mississippi USA
Posted: 6th Dec 2013 20:36
I tried a texture from a window in fps and then in reload in fps it worked great dirty glass you could see through in fps but in reload it was like looking through a fence no half way. I don't think reload is set up for it yet I think it was only for the fence example Could be wrong though
PM
Green Gandalf
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Location: Cornwall UK
Posted: 7th Dec 2013 01:52
Quote: "i am very interested.

I love to see a demo object"




The attached modified version of the stock canvas tent is a simple example of what I had in mind - but it's not ideal, i.e. too "grainy" really.



The all or nothing issue is hard to get around - but might be OK in some situations though.





Powered by Free Banners
pianodavy
11
Years of Service
User Offline
Joined: 5th Nov 2013
Location: United States
Posted: 7th Dec 2013 16:50
Nice try GG - but, it is still basically a 0/100% opaque/transparent mixed rendering. I'm guessing that there is going to have to be serious modifications coded to FPSCR's rendering engine in order for the program to enable 3D artists to render glass and concrete in a single object properly. I can't imagine that the development team will sacrifice this essential means for semi-realistic environments (even low quality 3D games and worlds feature this common available asset) for any reason - it's not like low end GPU's haven't been able to handle recreating multitudes of optical variations for years now. Honestly, my confidence in the developers is still rock solid. I'm sure Lee Bamber and his associates won't find this challenge very daunting, they've all shown themselves to be amazing coders thus far. Thanks for your efforts, too, GG - I very appreciate your efforts to increase the program's potential.

All you need is love....so let me have your burger.
Green Gandalf
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Location: Cornwall UK
Posted: 7th Dec 2013 18:12
I'm sure you're right - and if I recall correctly you could have reflective glass panels in FPSC9 (or was it FPSC10?) which would have used alpha blending.



The problem tends to be with a scene which has several semi transparent objects lined up behind each other - if the render order is wrong you can get very weird results from certain angles.



I guess it's one of those things that low on Lee's list of priorities at the moment.





Powered by Free Banners
granada
Forum Support
22
Years of Service
User Offline
Joined: 27th Aug 2002
Location: United Kingdom
Posted: 7th Dec 2013 20:18
Hi guys,this is a texture taken from FPS creator.So they will work,its just a matter of trying to work it out .











Dave

AMD Phenom(tm)IIx6 1090t Processor 3.20 GHS

8.00 GB memory Windows 7 64 bit

Nvida Geforce GTX 580
PM
Green Gandalf
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Location: Cornwall UK
Posted: 8th Dec 2013 01:25
Are any of those semi-transparent? They look all or none to me.





Powered by Free Banners
granada
Forum Support
22
Years of Service
User Offline
Joined: 27th Aug 2002
Location: United Kingdom
Posted: 8th Dec 2013 01:33
Quote: "They look all or none to me"




Your right,thats the part i'me trying to work out.



Dave

AMD Phenom(tm)IIx6 1090t Processor 3.20 GHS

8.00 GB memory Windows 7 64 bit

Nvida Geforce GTX 580
PM
pianodavy
11
Years of Service
User Offline
Joined: 5th Nov 2013
Location: United States
Posted: 8th Dec 2013 07:47
Nice try, Dave. Still it comes down to 100% opacity with 100% transparency as the best this engine seems to be able to accomplish in it's rendering faculties. On the other hand, the program very nicely renders it's water both transparent and reflective - I'm guessing this is due to the water_basic.fx coding applied to it. Looking at the code in Notepad, one can see it is intended for specific optical manipulation, the author Evolved titling it "Reflective/Refractive". I wouldn't know where to begin to edit the code to make it useful for the creation of varied partial transparencies on an object or if it is even possible to do so, for that matter. Furthermore, in depth study of the code language to achieve this end would really defeat one of the main ideals of this software - to be able to make games without extensive coding abilities. But I admit, it is driving me nuts and my curiosity won't seem to let this issue rest. And I'm guessing that there is not a model maker out there who can rest once they discover they cannot map realistic windows on their buildings and vehicles... at least not the ones who care for convincing realism in their creations.

All you need is love....so let me have your burger.
rolfy
18
Years of Service
User Offline
Joined: 23rd Jun 2006
Location:
Posted: 8th Dec 2013 08:21 Edited at: 8th Dec 2013 08:24
I wouldn't sweat it so much, semi transparency is still be introduced into the code obviously and you can guarantee it wont be left out. No point in trying to shoehorn it in yourself as it will be in there at some point.





Quote: "The problem tends to be with a scene which has several semi transparent objects lined up behind each other - if the render order is wrong you can get very weird results from certain angles."


Setting transparency to '2' would solve culling issues
Green Gandalf
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Location: Cornwall UK
Posted: 8th Dec 2013 10:55 Edited at: 8th Dec 2013 10:56
Quote: "Setting transparency to '2' would solve culling issues"




Not sure what you mean by that. Mode 2 merely says "2 and 3 - draw second which overlaps solid geometry" - from the DBPro Help file (assuming that's what you meant ). That's fine if you only have one transparent object with a fairly simple geometry but not if you have lots. You still need the transparent objects to be rendered in the correct order from back to front. The engine would need to sort that out.



Have a look at the screenshots below - especially the tree in the centre of the scene. Part of the trunk is missing when you use mode 2 presumably because the leaf plane in front of it was rendered first by accident. It might be possible to avoid that by applying the modes to the limbs rather than to the whole tree object - but you can still have leaf limbs near to the camera rendered before more distant leaf planes where the same problem arises.



Perhaps there's another way round this?









Powered by Free Banners
rolfy
18
Years of Service
User Offline
Joined: 23rd Jun 2006
Location:
Posted: 8th Dec 2013 11:52 Edited at: 8th Dec 2013 12:01
Quote: "I'm sure you're right - and if I recall correctly you could have reflective glass panels in FPSC9 (or was it FPSC10?) which would have used alpha blending.

The problem tends to be with a scene which has several semi transparent objects lined up behind each other - if the render order is wrong you can get very weird results from certain angles."
I was referring to this statement, I never have used DBP, in FPSC x9 setting transparency in the .fpe to '2' would ensure that transparent objects were drawn according to order of which was in front of camera no mattter how many, so no culling issues with other transparent objects behind. There were other settings but I cant remember offhand what they did
Green Gandalf
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Location: Cornwall UK
Posted: 8th Dec 2013 13:25 Edited at: 8th Dec 2013 14:02
Quote: "in FPSC x9 setting transparency in the .fpe to '2' would ensure that transparent objects were drawn according to order of which was in front of camera no mattter how many, so no culling issues with other transparent objects behind."




I didn't know that. Thanks.



That's interesting. Since FPSC9 was also built using DBPro that suggests it should be possible in DBPro natively (unless Lee added lots of special code for that). Sounds like I may have missed an option somewhere, a global object setting perhaps? I'll do some delving.



You've confirmed what I thought was possible in FPSC9 though - the question (for me) is how is it done in code? Fortunately most users of FPSCR won't need to worry about that.



Edit Found a relevant discussion (for the DBPro coders here):



http://forum.thegamecreators.com/?m=forum_view&t=179986&b=1



That doesn't seem to solve my problem though since the render sorting seems to be per object rather than by poly or limb. I'll be interested to see how FPSCR deals with this when the time comes.





Powered by Free Banners
Uman
GameGuru TGC Backer
20
Years of Service
User Offline
Joined: 22nd Oct 2004
Location:
Posted: 14th Dec 2013 06:37
Yes I am having the Transparency Issue too and seems like Reloaded does not support ranges of transparency e.g. levels of grey/black and only black as fully transparent. Glass and alike is therefore a problem.



Took me quite a few wasted hours before I came here to find out others were having the issue.



spudnick
13
Years of Service
User Offline
Joined: 30th Nov 2010
Location:
Posted: 21st Dec 2013 10:59
I have also been looking into Transparency and and found their is not a shader supporting it at the moment.



In Fpsc there is a shader called " cubeent.fx " that is used for windows.



ok lets see if i can create and get a shader to work in Reloaded for all.
PM
nomis
13
Years of Service
User Offline
Joined: 20th Apr 2011
Location:
Posted: 21st Dec 2013 13:54
Hi



i have change some values in the entity_basic.fx shader.

so you can use Partial Transparency.



have fun!!
PM
nomis
13
Years of Service
User Offline
Joined: 20th Apr 2011
Location:
Posted: 21st Dec 2013 13:59 Edited at: 21st Dec 2013 14:01
here a screenshot



edit: use it with beta1.004
PM
Pirate Myke
Forum Support
14
Years of Service
User Offline
Joined: 31st May 2010
Location: El Dorado, California
Posted: 21st Dec 2013 16:31 Edited at: 22nd Dec 2013 06:28
Looks good. I will give it a shot. Thanks



Edit:

I gave the shader a try, added alpha opacity to all three of the textures and saved them to BC3/dxt5 format in Gimp. Applied it to my model and ran the test game. I could not get it to work.



Are the normal in your box facing the inside?

nomis
13
Years of Service
User Offline
Joined: 20th Apr 2011
Location:
Posted: 22nd Dec 2013 11:31
Yeah the normals are facing inside i scald it up the wrong way.



you must save the texture with alpha channel, dxt5 should be ok. but i dont use gimp.



here is my box, this time with "normal" normals and the texture i use.



try it.
PM
Pirate Myke
Forum Support
14
Years of Service
User Offline
Joined: 31st May 2010
Location: El Dorado, California
Posted: 22nd Dec 2013 16:15
spudnick
13
Years of Service
User Offline
Joined: 30th Nov 2010
Location:
Posted: 30th Dec 2013 01:06 Edited at: 30th Dec 2013 01:08
i wonder why the AlphaBlendEnable were not set to True in the first place.



Anyway very pleased you solved this Nomis

PM
nomis
13
Years of Service
User Offline
Joined: 20th Apr 2011
Location:
Posted: 30th Dec 2013 13:28
I've also wondered.



but im not hundert procent happy with that. Everything behind the trancparency disapers.
PM
spudnick
13
Years of Service
User Offline
Joined: 30th Nov 2010
Location:
Posted: 30th Dec 2013 18:11
i have not tried using transparent objects yet so have not seen what disapears or whats going on.



from what your saying is that if you use a window thus using transparent glass that everything on the over side disapears. but everything looks ok from the first side that you look through, erm confusing lol



can you post a picture from working side and from problem side, as very interested to see.
PM
nomis
13
Years of Service
User Offline
Joined: 20th Apr 2011
Location:
Posted: 3rd Jan 2014 19:46 Edited at: 3rd Jan 2014 19:48
Here is a viedo form the Transparency:

http://www.youtube.com/watch?v=i2Y1eZyh7aw&feature=youtu.be

Its only the grass that disaperd.
PM
pianodavy
11
Years of Service
User Offline
Joined: 5th Nov 2013
Location: United States
Posted: 22nd Feb 2014 04:30 Edited at: 22nd Feb 2014 04:45
Thank you so much for your modification, nomis. Here is a screenshot showing the amazing success of your work. The frame on the left has both a 100% opaque and a roughly 65% transparency on it's single map. As one can see, the inside pane where the transparency is mapped is totally useless, for it is as clear as invisible. I tried walking through the center by putting it halfway in the ground, but the middle polys were there - which i was relieved to find out - they acted as an invisible barrier. This was not what we want. Nomis modified the entity_basic.fx file (make sure you rename it if you choose to use it). I applied this effect in the .fpe file to the frame on the right. Now you can clearly see the frame is still solid, but the "glass" part of my frame, which has the rainbow part of my texture, which in turn was given partial transparency (this is the same texture as the frame/window applied on the left), is now see through but not invisible. This is really so very important for windows, speaking of which I have another thread I will be writing about very soon because this feature should be considered of vital importance by any serious model maker - especially if designing all sorts of vehicles. Thanks so very much, nomis!

All you need is love....so let me have your burger.
spudnick
13
Years of Service
User Offline
Joined: 30th Nov 2010
Location:
Posted: 22nd Feb 2014 09:58
Hi Pianodavey and no is,



Has the problem of disappearing entities from other side of transparent obejct been resolved?

If not then could you send me the above model with fpe file, as I think I have found a solution by it having the objects own shader,

Its just I have no transparent objects to tryout.

Thx
PM
rolfy
18
Years of Service
User Offline
Joined: 23rd Jun 2006
Location:
Posted: 22nd Feb 2014 10:13 Edited at: 22nd Feb 2014 10:39
You guy's might want to be careful with posting these shaders according to info given here in this thread.



http://fpscrforum.thegamecreators.com/?m=forum_view&t=207920&b=1



I think you might be alright with your water shaders Spudnick as these are by Evolved but posting any by Mark Blosser looks like a no-no.



Quote: "And you're right about not publishing the shader, snippets are fine, the whole shader wouldn't be.



SC"




As for culling of objects behind transparency this was cured in Classic by setting transparency to '2' in the entity fpe you might want to try it and see. I already mentioned this above but don't see anyone taking any notice and actually testing it. Personally I haven't seen this culling with any of my own media.

Lee-"...and before you know it you're a shader coder!"



rolfy-"Coding...To me this is the Dark Arts..don't blame me when something Evil comes to claim y'all if I dabble in it"
pianodavy
11
Years of Service
User Offline
Joined: 5th Nov 2013
Location: United States
Posted: 22nd Feb 2014 13:48
Thanks for the heads up about posting shaders, rolfy - although that is nothing I have ever done - I am a firm believer in respecting copyright laws as we all benefit from them. I do admit, I used the modification that nomis adjusted - of course as you know he was just trying to be helpful, nonetheless, it would probably be wiser to simply use a snippet of adjustment and allow others to modify their own segments to avoid the technical but true violation of publishing protected property. I didn't notice anything disappearing behind my frame/window - I think nomis did report that grass disappeared so maybe there is still an alpha sequencing problem with this code. This will be a problem if you're flying in a vehicle with transparent windows for whatever reason - the trees probably won't show any leaves and so forth - I don't know yet - I'm almost finished with a spacecraft I'm working on with a transparent cockpit lid - I'll let you know what happens with it!

All you need is love....so let me have your burger.
rolfy
18
Years of Service
User Offline
Joined: 23rd Jun 2006
Location:
Posted: 23rd Feb 2014 01:41
Yeah I know no is harm intended. The issue of transparency culling in Classic was exactly the same and fixed as I say above, there are a few transparency settings and wHat they do I can't remember off the top of my head.Mostly it culls other dynamic objects behind transparency with a setting of '1'..

Lee-"...and before you know it you're a shader coder!"



rolfy-"Coding...To me this is the Dark Arts..don't blame me when something Evil comes to claim y'all if I dabble in it"

Login to post a reply

Server time is: 2024-11-21 17:46:10
Your offset time is: 2024-11-21 17:46:10