mirror of https://github.com/axmolengine/axmol.git
closed #4096: add s3tc bitmap with no mipmaps test case.
This commit is contained in:
parent
3cfd9e9c08
commit
4410e70ca1
|
@ -95,6 +95,7 @@ static std::function<Layer*()> createFunctions[] =
|
||||||
CL(TextureS3TCDxt1),
|
CL(TextureS3TCDxt1),
|
||||||
CL(TextureS3TCDxt3),
|
CL(TextureS3TCDxt3),
|
||||||
CL(TextureS3TCDxt5),
|
CL(TextureS3TCDxt5),
|
||||||
|
CL(TextureS3TCWithNoMipmaps),
|
||||||
|
|
||||||
CL(TextureATITCRGB),
|
CL(TextureATITCRGB),
|
||||||
CL(TextureATITCExplicit),
|
CL(TextureATITCExplicit),
|
||||||
|
@ -2137,6 +2138,20 @@ std::string TextureS3TCDxt5::subtitle() const
|
||||||
return "S3TC dxt5 decode";
|
return "S3TC dxt5 decode";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//Implement of S3TC with no mipmaps
|
||||||
|
TextureS3TCWithNoMipmaps::TextureS3TCWithNoMipmaps()
|
||||||
|
{
|
||||||
|
auto sprite = Sprite::create("Images/test_512x512_s3tc_dxt5_with_no_mipmaps.dds");
|
||||||
|
auto size = Director::getInstance()->getWinSize();
|
||||||
|
sprite->setPosition(Point(size.width / 2, size.height / 2));
|
||||||
|
|
||||||
|
addChild(sprite);
|
||||||
|
}
|
||||||
|
std::string TextureS3TCWithNoMipmaps::title() const
|
||||||
|
{
|
||||||
|
return "S3TC with no mipmaps";
|
||||||
|
}
|
||||||
|
|
||||||
//Implement of ATITC
|
//Implement of ATITC
|
||||||
TextureATITCRGB::TextureATITCRGB()
|
TextureATITCRGB::TextureATITCRGB()
|
||||||
{
|
{
|
||||||
|
|
|
@ -566,6 +566,17 @@ public:
|
||||||
virtual std::string subtitle() const override;
|
virtual std::string subtitle() const override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
// S3TC texture with no mipmaps test
|
||||||
|
class TextureS3TCWithNoMipmaps : public TextureDemo
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
CREATE_FUNC(TextureS3TCWithNoMipmaps);
|
||||||
|
TextureS3TCWithNoMipmaps();
|
||||||
|
|
||||||
|
virtual std::string title() const override;
|
||||||
|
};
|
||||||
|
|
||||||
// ATITC RGB texture format test
|
// ATITC RGB texture format test
|
||||||
class TextureATITCRGB : public TextureDemo
|
class TextureATITCRGB : public TextureDemo
|
||||||
{
|
{
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
359857b480448e4fc5d2cb926ac597ca1a587dfb
|
Loading…
Reference in New Issue