MCPcopy Create free account
hub / github.com/axmolengine/axmol / setSpriteFrameInfo

Method setSpriteFrameInfo

core/base/NinePatchImageParser.cpp:174–181  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

172}
173
174void NinePatchImageParser::setSpriteFrameInfo(Image* image, const ax::Rect& frameRect, bool rotated)
175{
176 this->_image = image;
177 AXASSERT(image->getPixelFormat() == backend::PixelFormat::RGBA8,
178 "unsupported format, currently only supports rgba8888");
179 this->_imageFrame = frameRect;
180 this->_isRotated = rotated;
181}
182
183bool NinePatchImageParser::isNinePatchImage(std::string_view filepath)
184{

Callers 2

Calls 1

getPixelFormatMethod · 0.45

Tested by 1