Pose¶
Description¶
Object position and rotation. Use with Shapes3D and Rasterizer3D.
gaspardos::graphics::Pose — bindings/cpp/raster3d.hpp, C++98.
Simple program example¶
#include "raster3d.hpp"
using namespace gaspardos::graphics;
int main()
{
Pose value;
return value.translation.z == 4 ? 0 : 1;
}
Building from Windows¶
From the repository root, save the program as build/api-examples/Pose.cpp.
New-Item -ItemType Directory -Force build/api-examples | Out-Null
& .\build-x64-install\bin\x86_64-gaspardos-g++.exe -std=c++98 -O2 -Ibindings/cpp build/api-examples/Pose.cpp bindings/cpp/raster3d.cpp -o build/api-examples/Pose.elf
if ($LASTEXITCODE -ne 0) { throw "C++ build failed" }
Executable for GaspardOS. Presentation requires WINDOW_BLIT=146 in the kernel; -38 means the extension is absent. Source files.
Methods and public data¶
Pose()¶
Zero rotation and translation (0,0,4).
Public fields¶
rotation, translation : Vec3