www.jpct.net

jPCT - a 3d engine for Java => Support => Topic started by: entis on February 12, 2008, 12:13:46 pm

Title: With transparency texture becomes much darker... How can I improve this?
Post by: entis on February 12, 2008, 12:13:46 pm
Hi,

While using sw renderer in jpct I get the following effect...

(http://img521.imageshack.us/img521/5428/forforumox8.th.gif) (http://img521.imageshack.us/my.php?image=forforumox8.gif)

How can I make my texture be as bright as without transparency (without using additional lights)?

Thanks.

Title: Re: With transparency texture becomes much darker... How can I improve this?
Post by: EgonOlsen on February 12, 2008, 02:36:31 pm
"Without" is darker in your pic. Shouldn't it be the other way round judging from the topic? I'm confused... ???
Title: Re: With transparency texture becomes much darker... How can I improve this?
Post by: entis on February 12, 2008, 02:58:02 pm
No 'without' shouldn't be darker actually... Just there are two green regions on my underlying texture (darker and lighter)... like grass on the football field... Just one screenshot (that is without transparency) I took when I was on the darker region of the underlying texture and another one (that is with transparency) I took when I was on the lighter region of the underlying texture... Just assume that the brigthness of the underlying textures are the same on the both parts... I'm wondering why with transparency my WHITE line is GREY and at the same time without transparency it's WHITE...
Title: Re: With transparency texture becomes much darker... How can I improve this?
Post by: EgonOlsen on February 12, 2008, 03:22:42 pm
That is most likely caused by the way the pixels are blended. What is your transparency setting (i.e. the value you are using in setTransparency(<int>)). You may try to use the additive transparency mode, that the 1.16 beta offers (a link to it can be found in this thread: http://www.jpct.net/forum2/index.php/topic,1014.0.html (http://www.jpct.net/forum2/index.php/topic,1014.0.html)).
Title: Re: With transparency texture becomes much darker... How can I improve this?
Post by: entis on February 12, 2008, 03:30:27 pm
Thanks for your fast feedback... Does it work for sw renderer also?
Title: Re: With transparency texture becomes much darker... How can I improve this?
Post by: EgonOlsen on February 12, 2008, 04:01:29 pm
In the 1.16 beta: yes. In the official 1.15: no.