3D Generation Modes
1. Text-to-3D
Generate a 3D model from a text description:
import requests
def text_to_3d(prompt: str, topology: str = "standard",
format: str = "glb") -> dict:
"""Generate 3D model from text description."""
response = requests.post(
"https://api.tripo3d.ai/v1/generate",
headers={"Authorization": f"Bearer {TRIPO_API_KEY}"},
json={
"type": "text_to_model",
"prompt": prompt,
"topology": topology,
"format": format,
}
)
return response.json()
Best for: concept exploration, rapid prototyping, creative assets Limitation: the model won't match a specific real-world object
2. Image-to-3D
Generate a 3D model from a single 2D image:
def image_to_3d(image_url: str, topology: str = "standard",
format: str = "glb") -> dict:
"""Generate 3D model from a single image."""
response = requests.post(
"https://api.tripo3d.ai/v1/generate",
headers={"Authorization": f"Bearer {TRIPO_API_KEY}"},
json={
"type": "image_to_model",
"image": image_url,
"topology": topology,
"format": format,
}
)
return response.json()
Best for: product visualization, e-commerce, accurate object reconstruction Advantage: the 3D model matches the actual object in the image
3. Multi-View Reconstruction
Generate a 3D model from multiple images taken from different angles:
def multi_view_to_3d(image_urls: list[str], format: str = "glb") -> dict:
"""Generate 3D model from multiple view images."""
response = requests.post(
"https://api.tripo3d.ai/v1/generate",
headers={"Authorization": f"Bearer {TRIPO_API_KEY}"},
json={
"type": "multi_view_to_model",
"images": image_urls, # List of URLs from different angles
"format": format,
}
)
return response.json()
Best for: photorealistic 3D, accurate reconstruction, product photography Advantage: multiple angles provide depth and detail that single images can't
You need a 3D model of a specific product for an e-commerce site. Which mode should you use?
Both image-to-3D and multi-view are correct. Image-to-3D uses a single product photo (simpler, faster). Multi-view uses photos from multiple angles (more accurate, more detailed). For e-commerce, start with image-to-3D for speed. If higher accuracy is needed (e.g., customer can rotate the product in 3D), use multi-view with 3-5 angles. Text-to-3D won't match the specific product.
4. Gaussian Splatting
Gaussian Splatting represents 3D scenes as collections of 3D Gaussians (particles) rather than meshes:
# Gaussian Splatting is a different 3D representation
# It's not mesh-based — it's a radiance field
# Key difference:
# Mesh: vertices + faces (polygons)
# Gaussian Splatting: 3D Gaussians with position, rotation, scale, color, opacity
# Advantages:
# - Photorealistic rendering
# - Real-time rendering (100+ FPS)
# - Captures view-dependent effects (reflections, transparency)
# Disadvantages:
# - Not editable (can't modify geometry)
# - Large file sizes
# - Not compatible with game engines (need mesh for games)
Gaussian Splatting vs Mesh
| Property | Gaussian Splatting | Mesh |
|---|
| Representation | 3D Gaussians (particles) | Vertices + faces |
| Rendering | Photorealistic, real-time | Good, depends on textures |
| Editability | Not editable | Fully editable |
| File size | Large (100MB+) | Small (1-50MB) |
| Game engine | Not supported | Fully supported |
| Best for | Photorealistic visualization | Games, AR/VR, animation |