Thanks to visit codestin.com
Credit goes to github.com

Skip to content

support img style filter#1161

Open
charles-liang wants to merge 1 commit intoliabru:masterfrom
charles-liang:master
Open

support img style filter#1161
charles-liang wants to merge 1 commit intoliabru:masterfrom
charles-liang:master

Conversation

@charles-liang
Copy link

render the style filter of the img at runtime

test code

const brightness = 0.5;
const texture = render.textures[body.render.sprite.texture]
const styleBrightness =  `brightness(${brightness})`;
texture.style.webkitFilter = styleBrightness;
texture.style.filter = styleBrightness;

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

Comments