Filter image babylon gui

Hi everyone,

I want to filter an image by increasing brightness for instance. I am using javascript syntax but it doesn’t work. what is the way to achieve this?

Hi,
At first, you might want to take a look at this section of the doc.
Let us know if anything…

As it seems these filters are used for the camera directly, in my case I have some images which should be filtered at some point of time. I think it’ll be better if I use image frames animated in adobe

to avoid using multiple cameras for each image

Thanks for you attention in work days too :laughing: :smiling_face_with_three_hearts:

Yes, I understand (and you are right in a way). If you want to use this image in your GUI you would need to apply treatment before rendering the advancedTexture layer. And, somehow, it doesn’t make much sense to me. I mean (unless you are building a GUI editor), it’s unlikely that your GUI images will change in brightness/contrast/hue or saturation. It is still completely possible and easy to do it for ALL your GUI (by using a two camera approach and post-processing for your GUI). But from what I understand, you wanted to make a single or per image processing configuration, correct? In which case, if it’s not for a dynamic or user input use, it would be definetely better and by far easier to just make the changes at image edit level.

1 Like

Sure, you can do it with an animation or use cellID. However, if you really need per imageProcessing treatment in BJS to use with GUI images…well, I have no faen clue how to do it :wink: But, I would be able to call in on your topic the one person who would know how to do it (if feasible at all). It would likely involve shaders treatment on the pictures before render. Now, I don’t want to disturb this person if it’s not an absolute necessity for your project. Else, let me know…

I’ll use image frames :heart_eyes:

for(let i=0; i<9999; i++) {
Thank you
}

That’s a very long and smooth animation. Just make sure it won’t have too much impact on performance.

ahh, I know, I just said as many “thank you” as possible to you :laughing:

1 Like

That’s very kind :smiling_face_with_three_hearts: of you and it’s totally fine. If we were not willing to help, we wouldn’t be here :smiley:
Have an amazing weekend :sunglasses:

2 Likes