class
#include <bn_regular_bg_tiles_item.h>
regular_bg_tiles_item Contains the required information to generate regular background tiles.
The assets conversion tools generate an object of this type in the build folder for each *.bmp file with regular_bg
type.
The tiles are not copied but referenced, so they should outlive the regular_
Public static functions
-
static auto valid_tiles_count(int tiles_count,
bpp_
mode bpp) -> bool constexpr - Indicates if the specified tiles count are valid for the specified bits per pixel or not.
Constructors, destructors, conversion operators
-
regular_bg_tiles_item(const span<const tile>& tiles_ref,
bpp_
mode bpp) constexpr - Constructor.
-
regular_bg_tiles_item(const span<const tile>& tiles_ref,
bpp_
mode bpp, compression_ type compression) constexpr - Constructor.
Public functions
- auto tiles_ref() const -> const span<const tile>& constexpr
- Returns the reference to one or more background tiles.
-
auto bpp() const -> bpp_
mode constexpr - Returns the bits per pixel of the referenced tiles.
-
auto compression() const -> compression_
type constexpr - Returns the compression type.
-
auto decompress(span<tile> decompressed_tiles_ref) const -> regular_
bg_ tiles_ item - Decompresses the stored data in the tiles referenced by decompressed_tiles_ref.
-
auto find_tiles() const -> optional<regular_
bg_ tiles_ ptr> - Searches for a regular_
bg_ tiles_ ptr which reference the background tiles. -
auto create_tiles() const -> regular_
bg_ tiles_ ptr - Searches for a regular_
bg_ tiles_ ptr which reference the background tiles. If they are not found, it creates a regular_ bg_ tiles_ ptr which reference them. -
auto create_tiles_optional() const -> optional<regular_
bg_ tiles_ ptr> - Searches for a regular_
bg_ tiles_ ptr which reference the background tiles. If they are not found, it creates a regular_ bg_ tiles_ ptr which reference them.
Friends
-
auto operator==(const regular_
bg_ tiles_ item& a, const regular_ bg_ tiles_ item& b) -> bool constexpr - Equal operator.
Function documentation
bn:: regular_bg_tiles_item:: regular_bg_tiles_item(const span<const tile>& tiles_ref,
bpp_ mode bpp) constexpr
Constructor.
Parameters | |
---|---|
tiles_ref | Reference to one or more background tiles. |
bpp | tiles_ref bits per pixel. |
The tiles are not copied but referenced, so they should outlive the regular_
bn:: regular_bg_tiles_item:: regular_bg_tiles_item(const span<const tile>& tiles_ref,
bpp_ mode bpp,
compression_ type compression) constexpr
Constructor.
Parameters | |
---|---|
tiles_ref | Reference to one or more background tiles. |
bpp | tiles_ref bits per pixel. |
compression | Compression type. |
The tiles are not copied but referenced, so they should outlive the regular_
const span<const tile>& bn:: regular_bg_tiles_item:: tiles_ref() const constexpr
Returns the reference to one or more background tiles.
The tiles are not copied but referenced, so they should outlive the regular_
regular_ bg_ tiles_ item bn:: regular_bg_tiles_item:: decompress(span<tile> decompressed_tiles_ref) const
Decompresses the stored data in the tiles referenced by decompressed_tiles_ref.
Parameters | |
---|---|
decompressed_tiles_ref | Destination of the decompressed tiles. |
Returns | A regular_ |
If the source and destination tiles overlap, the behavior is undefined.
optional<regular_ bg_ tiles_ ptr> bn:: regular_bg_tiles_item:: find_tiles() const
Searches for a regular_
Returns | regular_ |
---|
regular_ bg_ tiles_ ptr bn:: regular_bg_tiles_item:: create_tiles() const
Searches for a regular_
Returns | regular_ |
---|
The tiles are not copied but referenced, so they should outlive the regular_
optional<regular_ bg_ tiles_ ptr> bn:: regular_bg_tiles_item:: create_tiles_optional() const
Searches for a regular_
Returns | regular_ |
---|
The tiles are not copied but referenced, so they should outlive the regular_
bool operator==(const regular_ bg_ tiles_ item& a,
const regular_ bg_ tiles_ item& b) constexpr
Equal operator.
Parameters | |
---|---|
a | First regular_ |
b | Second regular_ |
Returns | true if the first regular_false . |