|
Player12
An open source football management simulator
|
#include <match_renderer_3d.h>
Classes | |
| struct | State |
Public Member Functions | |
| MatchRenderer3D () | |
| ~MatchRenderer3D () override | |
| MatchRenderer3D (const MatchRenderer3D &)=delete | |
| MatchRenderer3D & | operator= (const MatchRenderer3D &)=delete |
| MatchRenderer3D (MatchRenderer3D &&)=delete | |
| MatchRenderer3D & | operator= (MatchRenderer3D &&)=delete |
| void | render (const MatchRenderSnapshot &snapshot, const MatchRenderOptions &options, const MatchViewport &viewport) override |
| bool | projectPitch (Vector2F pitch, float heightMetres, float &screenX, float &screenY) const override |
Public Member Functions inherited from IMatchRenderer | |
| virtual | ~IMatchRenderer ()=default |
Private Attributes | |
| std::unique_ptr< State > | state |
Stylised 3D broadcast renderer.
Projects a metric world through a perspective camera on the CPU and draws the result as ImDrawList triangles, so it shares the SDL_Renderer/ImGui path with the 2D view. Static geometry (pitch, markings, stands, crowd, boards, goals) is built once and only re-projected; players, ball and goal parts are depth-sorted back to front each frame (painter's algorithm) with near-plane clipping for ground polygons. Consumes only the read-only snapshot and never touches the simulation.
| MatchRenderer3D::MatchRenderer3D | ( | ) |
|
overridedefault |
|
delete |
|
delete |
|
delete |
|
delete |
|
overridevirtual |
Screen position (logical pixels) of a normalised pitch point at a height in metres, as drawn by the last render(), so overlays can be drawn in the view's projection. False before the first frame or when the point is behind the camera.
Implements IMatchRenderer.
|
overridevirtual |
Implements IMatchRenderer.
|
private |