#How to get UV pos given longitude and latitude

5 messages · Page 1 of 1 (latest)

sharp turret
#

can someone tell me how to get UV pos given longitude and latitude please?

modern flicker
#

function latLongToEquirectangularUV(lat, long) {
const u = (long + 180) / 360;
const v = (lat + 90) / 180;
return { u, v };
}

#

(gpt4 be careful!)

pulsar pond
#

UVs only mean anything in the context of a particular mesh

#

if you have lat/long i guess you're drawing a map, maybe? UVs for the default three.js sphere are one thing. UVs on a plane would be another, there are any number of map projections you might choose there.