in addition to @Chrome_Cat's improvements, I have converted the costumes to bitmap. Original Instructions by @Chrome_Cat: this is a massive upgrade to STTF - 100% accurate (including thin triangles) - 20% faster - 50% less warping - smoother edges - less jitter and bugs - Added new demo mode
Using an exploit shared by @skyistumbling that involves increasing the stage size, it's possible to store bitmap costumes that are larger than the maximum "size" of 480x360. Using this trick, the vector costumes, which are 512x512 resolution, can be converted to bitmap. One consequence of the conversion is that the invisible circle that STTF relies on for increasing the bounding box of the sprite gets rasterized into nonexistence. As a replacement, a pixel of near complete transparency is placed in the top left and bottom right corners. This should theoretically decrease RAM usage, since Scratch will no longer generate massive uncompressed "silhouette" textures for the triangle costumes, like it would if they were vector. Someone test this please Original Notes and Credits by @Chrome_Cat: - I found a solution to the equation so the inaccuracy due to using an interpolation table is fixed. - Calculated optimal displacement (S) to be 4 not 1.5 - Used svg's clip-path to split the images for smoother edges - new equations have 20% less operations Link to texture_converter: https://joeclinton1.github.io/texture-converter-js/ Link to original: https://scratch.mit.edu/projects/723419988/ Link to explanation document: https://scratch.mit.edu/projects/887818824/ ------------------------ Issues ----------------------------- - High ram usage: 100MB per quad = max 15 quad textures. (unless using turbowarp) ---------------------- Credits -----------------------------------Cube engine: , fisheye stretch idea: cached scene demo: ---------------------- Dev log ----------------------------------- 20/08 - v0.1 - Shared initial release version 03/12 - v1.0 - fixed all bugs 02/09 - V1.4 - constant generator and bounding circle 06/09 - V2.0 - New closed form equations, clippath split, S=4