default object transparency

Started by raft, January 11, 2011, 07:37:49 PM

Previous topic - Next topic

raft

i set Config.glTransparencyMul to a low value (0.001) for finer control over transparency. but then some of my objects became invisible. seems as Loader.load3DS(InputStream, scale); sets transparency to 100 and in my case this makes my objects almost invisible.

it may make sense if Loader sets transparency to -1.

EgonOlsen

Actually it sets them to whatever the 3ds file says. I don't remember the exact formula that i'm using to convert 3ds' transparency value to jPCT's, but if the object in the file has no transparency set, the loader shouldn't set one either.

raft

i see. but that's strange indeed. the objects in question are constructed via 3d Max's primitives and nothing has been set for transparency. maybe 3ds exporter's behaviour changed over time

AGP

There's a setting in Config for using the old importer. Have you tried that one, and could that help?

EgonOlsen

Quote from: raft on January 11, 2011, 08:36:05 PM
i see. but that's strange indeed. the objects in question are constructed via 3d Max's primitives and nothing has been set for transparency. maybe 3ds exporter's behaviour changed over time.
Didn't we had a similar issue with some sky dome in Karga after implementing that feature in the loader? Everything went darker, because the dome now had a transparency set?

AGP

So again, does using the old loader solve it?

raft

Quote from: AGP on January 11, 2011, 08:43:53 PM
There's a setting in Config for using the old importer. Have you tried that one, and could that help?
now i tried it but didnt help.

Quote from: EgonOlsen on January 11, 2011, 08:47:46 PM
Didn't we had a similar issue with some sky dome in Karga after implementing that feature in the loader? Everything went darker, because the dome now had a transparency set?
to tell the truth, i can't remember

i have a solution, setting transparency to -1. but still seems to me this transparency cames from nowhere ;)

EgonOlsen

It comes from the file. No idea why, but if the loader loads it, it's in there...

raft

agreed. i meant i came from nowhere to file  ;)

EgonOlsen

I'll try to find that skydome issue later...maybe that helps to find out where it comes from.


raft

thanks. seems as the same issue as you said. i had found that sky dome from web so i dont how it's exported. so this leads us us to where ?

EgonOlsen


AGP

Is the current problem related to a sky dome? We have a SkyBox class now on jpct...

raft

no, most of the objects i exported from 3dMax comes with this strange transparency. i just couldnt figure out how they got into 3ds file.

not a real problem indeed. setting transparency to -1 solves the issue.