Remesh
A critical step in the 3D production pipeline. Models directly from AI often contain messy triangles that are inefficient and hard to rig. This service converts messy meshes into clean quad-based topology for better performance and animation.
Typical Application Scenarios
- LOD Optimization: Optimize ultra-high-poly models into low-poly versions suitable for real-time mobile rendering.
- Animation Pipeline: Generate clean quad meshes to ensure smooth, natural deformation after skeletal binding.
API Reference used on this page POST /3d_models/remeshings
3D Model Input Formats
Model parameters accept three formats:
- Previous task result: Use the
asset_pathfrom a text/image-to-3D task directly — no re-upload needed - Base64 encoding: Pass the raw base64-encoded
.glbfile content (nodata:prefix) - Public URL: Any accessible
.glbor supported format file link
Basic Examples
bash
curl -X POST 'https://api.v2fun.ai/api/v1/3d_models/remeshings' \
-H 'Authorization: Bearer $V2FUN_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"input_model": "models/example.glb"
}'javascript
const response = await fetch('https://api.v2fun.ai/api/v1/3d_models/remeshings', {
method: 'POST',
headers: {
'Authorization': 'Bearer $V2FUN_API_KEY',
'Content-Type': 'application/json',
},
body: JSON.stringify({
"input_model": "models/example.glb"
}),
});
const data = await response.json();python
import requests
resp = requests.post(
'https://api.v2fun.ai/api/v1/3d_models/remeshings',
headers={
'Authorization': 'Bearer $V2FUN_API_KEY',
'Content-Type': 'application/json',
},
json={
"input_model": "models/example.glb"
},
)
print(resp.json())java
import java.net.URI;
import java.net.http.*;
HttpClient client = HttpClient.newHttpClient();
String body = "{\"input_model\":\"models/example.glb\"}";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.v2fun.ai/api/v1/3d_models/remeshings"))
.header("Authorization", "Bearer $V2FUN_API_KEY")
.header("Content-Type", "application/json")
.POST(HttpRequest.BodyPublishers.ofString(body))
.build();
HttpResponse<String> response = client.send(
request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Core Use Cases
LOD Mesh Reduction
By setting mesh_count, you can generate different precision versions of the same asset. For example, reduce a 500k-poly model to 10k polys in one click.
bash
curl -X POST 'https://api.v2fun.ai/api/v1/3d_models/remeshings' \
-H 'Authorization: Bearer $V2FUN_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"input_model": "https://asset.v2fun.ai/upload/remesh-input-robot.glb",
"mesh_count": 10000
}'javascript
const response = await fetch('https://api.v2fun.ai/api/v1/3d_models/remeshings', {
method: 'POST',
headers: {
'Authorization': 'Bearer $V2FUN_API_KEY',
'Content-Type': 'application/json',
},
body: JSON.stringify({
"input_model": "https://asset.v2fun.ai/upload/remesh-input-robot.glb",
"mesh_count": 10000
}),
});
const data = await response.json();python
import requests
resp = requests.post(
'https://api.v2fun.ai/api/v1/3d_models/remeshings',
headers={
'Authorization': 'Bearer $V2FUN_API_KEY',
'Content-Type': 'application/json',
},
json={
"input_model": "https://asset.v2fun.ai/upload/remesh-input-robot.glb",
"mesh_count": 10000
},
)
print(resp.json())java
import java.net.URI;
import java.net.http.*;
HttpClient client = HttpClient.newHttpClient();
String body = "{\"input_model\":\"https://asset.v2fun.ai/upload/remesh-input-robot.glb\",\"mesh_count\":10000}";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.v2fun.ai/api/v1/3d_models/remeshings"))
.header("Authorization", "Bearer $V2FUN_API_KEY")
.header("Content-Type", "application/json")
.POST(HttpRequest.BodyPublishers.ofString(body))
.build();
HttpResponse<String> response = client.send(
request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Input Model
Output
Quad Topology Conversion
Switch topology to quad. Quads are preferred by animators because they follow the object's deformation forces perfectly, eliminating the "stretching" feel in animations.
mesh_topology: triangle · quad
bash
curl -X POST 'https://api.v2fun.ai/api/v1/3d_models/remeshings' \
-H 'Authorization: Bearer $V2FUN_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"input_model": "https://asset.v2fun.ai/upload/remesh-input-robot.glb",
"mesh_topology": "quad",
"mesh_count": 5000
}'javascript
const response = await fetch('https://api.v2fun.ai/api/v1/3d_models/remeshings', {
method: 'POST',
headers: {
'Authorization': 'Bearer $V2FUN_API_KEY',
'Content-Type': 'application/json',
},
body: JSON.stringify({
"input_model": "https://asset.v2fun.ai/upload/remesh-input-robot.glb",
"mesh_topology": "quad",
"mesh_count": 5000
}),
});
const data = await response.json();python
import requests
resp = requests.post(
'https://api.v2fun.ai/api/v1/3d_models/remeshings',
headers={
'Authorization': 'Bearer $V2FUN_API_KEY',
'Content-Type': 'application/json',
},
json={
"input_model": "https://asset.v2fun.ai/upload/remesh-input-robot.glb",
"mesh_topology": "quad",
"mesh_count": 5000
},
)
print(resp.json())java
import java.net.URI;
import java.net.http.*;
HttpClient client = HttpClient.newHttpClient();
String body = "{\"input_model\":\"https://asset.v2fun.ai/upload/remesh-input-robot.glb\",\"mesh_topology\":\"quad\",\"mesh_count\":5000}";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.v2fun.ai/api/v1/3d_models/remeshings"))
.header("Authorization", "Bearer $V2FUN_API_KEY")
.header("Content-Type", "application/json")
.POST(HttpRequest.BodyPublishers.ofString(body))
.build();
HttpResponse<String> response = client.send(
request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());Input Model
Output
