3. Operations#
This section explains all the operations required to transform the values entered by the user into a camera positioned in 3D space. The user defined values are the alpha & beta angles and the z reduction coefficient for the oblique case. The computed results are the position of the camera in 3D model space expressed by the altitude and rotation angle pair.
Hint
Angle values are displayed in degrees but computed in radians.
3.1. Axonometric Camera#
3.1.1. Input Values#
Attribute |
Description |
Condition |
|---|---|---|
alpha |
The alpha angle of the plan |
|
beta |
The beta angle of the plan |
|
3.1.2. Math Operations#
# |
Variables |
Description |
Functions |
|---|---|---|---|
1 |
alpha, beta |
Computes the reduction factors for x, y, and z. |
|
2 |
alpha, beta, z |
Computes the projection altitude |
|
3 |
alpha, beta, x, y, z |
Computes the projection rotation |
|
alpha, beta |
|||
4 |
x, y, z |
Normalizes the reduction factors for display purposes (informational) |
3.1.3. Output Values#
Attribute |
Description |
|---|---|
altitude |
Computed altitude angle of the camera |
rotation |
Computed rotation angle of the camera |
3.2. Oblique Camera#
Hint
Blender does not natively support oblique projections. To work around this limitation, a small workaround (“hack”) is used.
The camera’s pixel ratio on the X axis is modified in order to stretch the rendered image. This adjustment is computed using the altitude of the projection.
Applied formula: pixel_ratio_x = 1 / sin(abs(altitude))
By combining the camera tilt with this adjusted pixel ratio, it becomes possible to approximate an oblique projection in Blender’s render output.
3.2.1. Input Values#
Attribute |
Description |
Condition |
|---|---|---|
alpha / beta |
The alpha and beta angles of the plane |
Their values are linked through the function |
z |
The z reduction factor of the plane |
|
3.2.2. Math Operations#
# |
Variables |
Description |
Functions |
|---|---|---|---|
1 |
z |
Computes the projection altitude using the z reduction factor |
|
2 |
beta |
Deduces the projection rotation from the beta angle (beta = rotation) |
3.2.3. Output Values#
Attribute |
Description |
|---|---|
altitude |
Computed altitude angle of the camera |
rotation |
Computed rotation angle of the camera |