I'm new to three.js and WebGL in general and I'm trying to make a simple earth globe in 3D with a SVG texture applied on it (so that I can zoom in without quality loss).
I tried to load a svg image instead of my png image. I worked, but the image was "rasterized" removing all advantages of using svg :/
Is is possible to do that ? If yes how ?
Thanks
this.loader = new THREE.TextureLoader();
this.loader.load("someimage.svg", texture => {
//create the sphere
const sphere = new THREE.SphereGeometry(RADIUS, SEGMENTS, RINGS);
//map the texture to the material. Read more about materials in three.js docs
const material = new THREE.MeshBasicMaterial({
map: texture,
overdraw: 0.5
});
//create a new mesh with sphere geometry.
const mesh = new THREE.Mesh(sphere, material);
//add mesh to globe group
this.globe.add(mesh);
});