OpenTTD Source: SpriteBounds Struct Reference

OpenTTD Source 15.3

Public Member Functions | Data Fields
SpriteBounds Struct Reference
Inheritance diagram for SpriteBounds:

## Public Member Functions
constexpr | SpriteBounds (const Coord3D< int8_t > &origin, const Coord3D< uint8_t > &extent, const Coord3D< int8_t > &offset)

## Data Fields
Coord3D< int8_t > | origin
| Position of northern corner within tile.
Coord3D< uint8_t > | extent
| Size of bounding box.
Coord3D< int8_t > | offset
| Relative position of sprite from bounding box.

## Detailed Description

Definition at line 18 of file sprite.h.

## Constructor & Destructor Documentation

## ◆ SpriteBounds()

constexpr SpriteBounds::SpriteBounds | ( | const Coord3D< int8_t > & | origin,
|  | const Coord3D< uint8_t > & | extent,
|  | const Coord3D< int8_t > & | offset
| ) |  |
| inlineconstexpr

Definition at line 24 of file sprite.h.

## Field Documentation

## ◆ extent

Coord3D<uint8_t> SpriteBounds::extent

Size of bounding box.

Definition at line 20 of file sprite.h.

Referenced by AddSortableSpriteToDraw(), DrawFoundation(), ReadSpriteLayout(), StationChangeInfo(), Aircraft::UpdateDeltaXY(), RoadVehicle::UpdateDeltaXY(), and Train::UpdateDeltaXY().

## ◆ offset

Coord3D<int8_t> SpriteBounds::offset

Relative position of sprite from bounding box.

Definition at line 21 of file sprite.h.

Referenced by AddSortableSpriteToDraw(), RoadVehicle::UpdateDeltaXY(), and Train::UpdateDeltaXY().

## ◆ origin

Coord3D<int8_t> SpriteBounds::origin

Position of northern corner within tile.

Definition at line 19 of file sprite.h.

Referenced by AddSortableSpriteToDraw(), DrawHouseInGUI(), DrawRailCatenaryRailway(), DrawTileSeqStruct::IsParentSprite(), ReadSpriteLayout(), SpriteLayoutProcessor::SpriteLayoutProcessor(), StationChangeInfo(), Aircraft::UpdateDeltaXY(), RoadVehicle::UpdateDeltaXY(), Ship::UpdateDeltaXY(), and Train::UpdateDeltaXY().

The documentation for this struct was generated from the following file:

- src/sprite.h