HaxeFlixel / HaxeFlixel/flixel
Major jittering when scaling and rotating sprites
Open
Nobody has claimed this yet.
- Dominant language
- Haxe
- Stars
- 2.2k
- Forks
- 522
- Avg merge
- 34m
- Merged PRs (30d)
- 1
Description
- Flixel version: github dev
Code snippet reproducing the issue:
package;
import flixel.FlxG;
import flixel.FlxSprite;
import flixel.FlxState;
import flixel.text.FlxText;
import flixel.tweens.FlxTween;
import flixel.ui.FlxButton;
import flixel.math.FlxMath;
class MenuState extends FlxState
{
override public function create():Void
{
FlxG.camera.pixelPerfectRender = true;
super.create();
var spr:FlxSprite = new FlxSprite();
spr.x += 0.5;
add(spr);
spr.screenCenter();
FlxTween.tween(spr.scale, {x: 3, y: 3}, 2, {type: FlxTween.PINGPONG});
}
override public function update(elapsed:Float):Void
{
super.update(elapsed);
}
}
This seems to have been introduced in a very recent commit. I'm looking into it now. Sprites jitter around when scaling on rotating.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Run the provided MenuState reproduction with FlxG.camera.pixelPerfectRender enabled, focusing on the FlxSprite while its scale is tweened and it is rotated. Compare the observed motion with pixel-perfect rendering disabled if useful. Done means sprites no longer jitter during scaling and rotation.
Written by the indexing model from the issue text.
Assessment
- Domain
- game-dev
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100