I am trying to scale the sprite, but the texture needs to be scaled using "pixelly", for example, retro games.
I know how to do this in OpenGL, but I'm not sure how to do it in Cocos2d.
How can I do it? Is there any way to get OpenGL? Or something through Cocos2d?
With Cocos2d 0.8 (the latter) it is very simple ...
You just call setAliasTexParameters on your texture ...
eg:
Sprite * aSprite = [Sprite spriteWithFile: @ "someTextureImage.png"];
[aSprite.texture setAliasTexParameters];
Cocos2dx v3
Sprite* my_sprite = Sprite::create("my_image.png"); my_sprite->getTexture()->setAliasTexParameters(); my_sprite->setScale(4);
.
Source: https://habr.com/ru/post/1714301/More articles:How to improve the installation speed of the debugger on the Blackberry jde4.6 simulator? - simulatorEntity Framework issue after adding a column to DB table - c #Database independent to_char function in SQLAlchemy - mysqlDownload Picture OnClick - htmlWCF and IIS 6 - WSDL Unaffected - wsdlhow to insert image in db like blob in zendframework - phpВызов клиента soap.NET - c#Intelligent HTML Coding - htmlJPA EntityManager deletes all records in the database - javaHow to delete a line from a text file based on "studentId"? - javaAll Articles