mirror of
https://github.com/aseprite/aseprite.git
synced 2024-11-20 14:21:45 +00:00
Minor change in doc::Tileset asserts
This commit is contained in:
parent
649f187fc9
commit
3ef3ee68e0
@ -121,6 +121,10 @@ void Tileset::remap(const Remap& remap)
|
||||
void Tileset::set(const tile_index ti,
|
||||
const ImageRef& image)
|
||||
{
|
||||
ASSERT(image);
|
||||
ASSERT(image->width() == m_grid.tileSize().w);
|
||||
ASSERT(image->height() == m_grid.tileSize().h);
|
||||
|
||||
#if _DEBUG
|
||||
if (ti == notile && !is_empty_image(image.get())) {
|
||||
TRACEARGS("Warning: setting tile 0 with a non-empty image");
|
||||
@ -154,16 +158,16 @@ tile_index Tileset::add(const ImageRef& image)
|
||||
void Tileset::insert(const tile_index ti,
|
||||
const ImageRef& image)
|
||||
{
|
||||
ASSERT(image);
|
||||
ASSERT(image->width() == m_grid.tileSize().w);
|
||||
ASSERT(image->height() == m_grid.tileSize().h);
|
||||
|
||||
#if _DEBUG
|
||||
if (ti == notile && !is_empty_image(image.get())) {
|
||||
TRACEARGS("Warning: inserting tile 0 with a non-empty image");
|
||||
}
|
||||
#endif
|
||||
|
||||
ASSERT(image);
|
||||
ASSERT(image->width() == m_grid.tileSize().w);
|
||||
ASSERT(image->height() == m_grid.tileSize().h);
|
||||
|
||||
ASSERT(ti >= 0 && ti <= m_tiles.size()+1);
|
||||
preprocess_transparent_pixels(image.get());
|
||||
m_tiles.insert(m_tiles.begin()+ti, image);
|
||||
|
Loading…
Reference in New Issue
Block a user