You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
varuvmap=atlas.uv();/* { TOP RIGHT BOTTOM LEFT 'name': [ [0,0], [1,0], [1,1], [0,1] ],} */
When I think of a quad, I think of four pairs of points, so instead of TOP, RIGHT, BOTTOM, and LEFT, I would expect something more like TOP-LEFT, TOP-RIGHT, BOTTOM-LEFT, BOTTOM-RIGHT.
The text was updated successfully, but these errors were encountered:
The order looks to me like BOTTOM-LEFT, BOTTOM-RIGHT, TOP-RIGHT, TOP-LEFT. I assume you're using uv coordinates where the origin is in the bottom left most corner? Because the existing docs don't suggest that either are correct?
Assuming the origin is implied to be in the top left, which I guess makes sense for canvas 2d, then the order is TOP-LEFT, TOP_RIGHT, BOTTOM_RIGHT, BOTTOM_LEFT. That's really going to trip up someone looking for uv coordinates if they're assuming uv coordinate system.
This library was originally written for use in voxel-texture. The coordinates are based on what is used in voxel.js and three.js. I'm happy to take a patch for improvements though. Thanks!
currently the docs for
atlas.uv()
state:When I think of a quad, I think of four pairs of points, so instead of
TOP
,RIGHT
,BOTTOM
, andLEFT
, I would expect something more likeTOP-LEFT
,TOP-RIGHT
,BOTTOM-LEFT
,BOTTOM-RIGHT
.The text was updated successfully, but these errors were encountered: