Jump to content

does "hasAlpha" work on "emissiveTexture" ?


Jouerose
 Share

Recommended Posts

Hello all, 

I was wondering whether from your experience, setting as true the hasAlpha property of an emissiveTexture work for you in the context of an image that has transparency ? if yes , could you please provide a simple playground example ? 

I know it works on diffuseTexture but so far I do not see it work on emissiveTexture.

thank you for your input and help

 

 

Link to comment
Share on other sites

Hi J... sorry for the slow replies, but you ask a great question.

https://www.babylonjs-playground.com/#KVRKS#12

I'm doing some experiments on my fake streetlights thing... lines 141-161 area.

I had a theory I wanted to test.  IF a material is using both emissiveTexture AND emissiveColor... I thought MAYBE... the alpha on the texture... would affect the amount of emissiveColor allowed to be seen thru the transparent parts of the emissiveTexture.  (wow, what a sentence!)  It seems not so, though, per my early tests.

It seems... alpha for textures put into the material emissiveTexture channel... is not used/considered. 

Still, that's a guess.  I really just wanted to provide a testing playground (and rattle-on aimlessly), here.  :)

Question remains open.  This question requires an answer from somebody smarter than I.  Slow weekend on the forum.   More activity/visitors in 2-3 days, likely.

Link to comment
Share on other sites

Babylon needs allot of features and there simply aren't the resources to have it all right now. If I had to choose a first feature, it would be a 32 bit texture to use with particles, and not the simple 24 bit usage as it is now.

DB

Link to comment
Share on other sites

@dbawel Not sure to follow the problem with particles as particles read data for 32bits textures already :) 

@Jouerose Just use the same texture in emissiveTexture and opacityTexture and the engine will read alpha from opacityTexture and emissive color from emissiveTexture 

 

Link to comment
Share on other sites

2 hours ago, Deltakosh said:

@dbawel Not sure to follow the problem with particles as particles read data for 32bits textures already :) 

@Jouerose Just use the same texture in emissiveTexture and opacityTexture and the engine will read alpha from opacityTexture and emissive color from emissiveTexture 

 

MERCI

Link to comment
Share on other sites

Hi @Deltakosh-

On my most recent project using particles (6 months ago), I was still not able to use an alpha channel on the texture for each particle as an alpha channel. As in the past, I was only able to use the black value in the 24 bit image to appear transparent. This is using either BLENDMODE. What am I missing, as I've utilized particles in many projects and have spent many many hours experimenting and delivering particle systems of every kind using the babylon.js framework.

So if there is a PG scene which clearly uses a 32 bit image with an 8 bit alpha channel for transparency, I would be very excited... as this will allow me to do so many things I've been writing my way around to accomplish in the past. As well, I'll feel my normal anger with myself for not finding how to accomplish this in the current and past versions. Which is why I've been baffled as to why I've not discovered before as all of the 32 bit alpha channel support has always existed in WebGL since I began using in production almost 5 years ago.

Thanks for reviewing this post, and I'll be waiting to see how the community responds.

Cheers,

DB

Link to comment
Share on other sites

Well I'm going to respond by telling you how "demanding" that post sounds.  My goodness, DB, you know you can catch more flies with honey than you can with dogstool.

(Actually, I haven't done laboratory-grade research on that, but you know what I mean.)

Them people who you are working-for... are they stressing you out?  Just let me know... I'll have a little talk with 'em.  :)

If your anus is all clinched-up, let me know if there's something I can do to relax it.  I hate seeing you grumpy... but I suspect that a flower will get more bending done... than a hammer will, in this situation.  (hug)

12 hours ago, dbawel said:

I'll be waiting to see how the community responds.

If you said... "I'll be gathering more research information and trying to chart the impacts of 32-bit opacity on other BJS materials/systems"... wouldn't that "feel" better, if you were in DK's very busy shoes?  *shrug* 

Sorry if I'm butting-in... but remember that you once stomped-off in frustration... and made us all lonely for you.  You're a valuable member around here... we want to see you happy and not sad.  Try to keep in mind that "life" is leaning-on all of us, in many different ways.  Stay cool... I'm sure DK/others will have 32-bit opacity news, asap.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...