-
-
Notifications
You must be signed in to change notification settings - Fork 451
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to add a background image to a rectangle? #653
Comments
There's actually not a great way to do that at the moment. This is because the texture formation is inspired with spritesheet animations in mind. To do what you're asking is a different methodology. I tried to reconcile the two, but it's going to take some time. Likely, it will be easier to set some configurations on You can see my working branch here: https://github.com/jonobr1/two.js/tree/issue-653-texture-sizing Not a great answer, but in the meantime I recommend making your image content the actual size you want to use it in. Or, you can use it like this: https://codepen.io/jonobr1/pen/rNdZNwM |
I want to add a background image to Two.Rectangle. The size of the background image can be increased to the same size as Two.Rectangle.
The text was updated successfully, but these errors were encountered: