Welcome,
Guest
. Please
login
or
register
.
April 21, 2026, 06:41:08 PM
Home
Help
Search
Login
Register
Tasharen Entertainment Forum
»
Support
»
NGUI 3 Support
»
Possible to get sprite UV coords from inside an atlas?
« previous
next »
Print
Pages: [
1
]
Author
Topic: Possible to get sprite UV coords from inside an atlas? (Read 3743 times)
Shifty Geezer
Full Member
Thank You
-Given: 7
-Receive: 9
Posts: 226
Possible to get sprite UV coords from inside an atlas?
«
on:
January 31, 2014, 06:32:27 AM »
As an optimisation I'd like to use the NGUI sprite atlas as the source of my in-game sprites. Is there a way to get sprite UVs so I can create a quad textured with the atlas texture and set the UVs to a specific image?
Logged
ArenMook
Administrator
Hero Member
Thank You
-Given: 337
-Receive: 1171
Posts: 22,128
Toronto, Canada
Re: Possible to get sprite UV coords from inside an atlas?
«
Reply #1 on:
January 31, 2014, 11:25:47 AM »
atlas.GetSprite("sprite name") gives you all you need (combined with texture's width and height)
Logged
Shifty Geezer
Full Member
Thank You
-Given: 7
-Receive: 9
Posts: 226
Re: Possible to get sprite UV coords from inside an atlas?
«
Reply #2 on:
February 01, 2014, 12:24:22 PM »
Thanks
Logged
Print
Pages: [
1
]
« previous
next »
Tasharen Entertainment Forum
»
Support
»
NGUI 3 Support
»
Possible to get sprite UV coords from inside an atlas?