16-825 Assignment 1: Rendering Basics with PyTorch3D
1. Practicing with Cameras
1.1 360-degree Renders
1.2 Re-creating the Dolly Zoom
2. Practicing with Meshes
2.1 Constructing a Tetrahedron
Number of Vertices: 4
[ 1.0, 1.0, 1.0]
[ 1.0, -1.0, -1.0]
[-1.0, 1.0, -1.0]
[-1.0, -1.0, 1.0]
Number of Faces: 4
[[0, 1, 2],
[0, 3, 1],
[0, 2, 3],
[1, 3, 2]]
2.2 Constructing a Cube
Number of Vertices: 8
[-1.0, -1.0, -1.0]
[ 1.0, -1.0, -1.0]
[ 1.0, 1.0, -1.0]
[-1.0, 1.0, -1.0]
[-1.0, -1.0, 1.0]
[ 1.0, -1.0, 1.0]
[ 1.0, 1.0, 1.0]
[-1.0, 1.0, 1.0]
Number of Faces: 12
[4, 5, 6], [4, 6, 7]
[0, 2, 1], [0, 3, 2]
[0, 7, 3], [0, 4, 7]
[1, 2, 6], [1, 6, 5]
[3, 6, 2], [3, 7, 6]
[0, 1, 5], [0, 5, 4]
3. Re-texturing a Mesh
Colors:
- Color 1 = [1.0, 0.5, 0.0]
- Color 2 = [0.0, 0.0, 1.0]
4. Camera Transformations
R_relative is a rotation matrix and T_relative is a translation vector; together they form the camera’s extrinsic transform mapping coordinates between frames.
Transformation 1
Relative Transformation:
R_relative =
[[ 0, 1, 0],
[-1, 0, 0],
[ 0, 0, 1]]
T_relative =
[0, 0, 0]
Transformation 2
Relative Transformation:
R_relative =
[[1, 0, 0],
[0, 1, 0],
[0, 0, 1]]
T_relative =
[0, 0, 2]
Transformation 3
Relative Transformation:
R_relative =
[[ 0, 0, 1],
[ 0, 1, 0],
[-1, 0, 0]]
T_relative =
[-3, 0, 3]
Transformation 4
Relative Transformation:
R_relative =
[[1, 0, 0],
[0, 1, 0],
[0, 0, 1]]
T_relative =
[0.5, -0.5, 0]
5. Rendering Generic 3D Representations
5.1 Rendering Point Clouds from RGB-D Images
5.2 Parametric Functions
5.3 Implicit Surfaces
| Aspect | Point Cloud | Mesh |
|---|---|---|
| Rendering Speed | Fast to capture/render; can slow with dense data | Efficient on GPUs; triangle pipelines are optimized |
| Rendering Quality | Often sparse/noisy; less realistic | Smooth surfaces; shading & textures |
| Ease of Use | Simple to generate from scanners/depth sensors | Needs reconstruction/cleanup; integrates well with 3D tools |
| Memory Usage | Lightweight unless very dense | Extra storage for faces/connectivity |
6. Do Something Fun
A simple fireworks animation by sampling points from a 3D mesh and launching them with random velocities under gravity. The points transition from a base color to a bright palette as they spread, and the frames are rendered into a rotating GIF.
7. (Extra Credit) Sampling Points on Meshes