-
Notifications
You must be signed in to change notification settings - Fork 7.1k
-
Notifications
You must be signed in to change notification settings - Fork 7.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Resolution of BitmapMask gets somehow corrupted on game resize #6769
Comments
Just a note 3.55.2 is OK |
I have a very similar bug. If I apply a bitmapMask and/or postFx to a container and then resize the game (and it returns to normal if i put the resolution back to what it was when I added these effects). 3.6: container disappears or gets stretched vertically (the new resolution just has a bigger height, i guess the shader references screen % for coords). It also stops "updating", meaning even the stretched image is frozen in time. EDIT: in 3.7 / 3.8 SpineObjects don't disappear, the whole container disappears if there's at least one spine object visible |
Very bad experience, I just added a mask. There was no problem at all in 3.55.2, but in 3.8.01, it was very bad. The content inside the mask is all blurred. When the mask is blocked, it is very normal. I hope to receive timely updates and handling.
|
There is a workaround for this - start the game with correct or larger size in config It happens when you resize the game from small to large, so if it is possible, try to start the game closest to target size or larger and it should be fine |
尝试过,依旧会模糊的。不过没有模糊那么多。 |
我的是在手机端全屏显示的,也就是宽高都是取的 window.innerWidth, window.innerHeight 我不清楚哪里的问题,经验欠缺,我贴一下我的配置,你方便就帮忙看一眼 : const container = document.getElementById(parentID)
const width = container.clientWidth
const height = container.clientHeight
const config = {
type: Phaser.AUTO,
scene: [AvgBootScene, AvgGameScene],
parent: parentID,
resolution: window.devicePixelRatio || 1,
width,
height
}
```
容器的宽高就是 100vw,vh |
@woshisheji 它会不会跟字体类型也有关系? |
Thank you for submitting this issue. We have fixed this and the fix has been pushed to the |
Phaser 3.80.1
When you create small game, resize it to large and then create mask and set it on object, the object resolution gets lowered and the object becomes pixelated.
Here is reproduction code:
Run the code, click on the scene and see the effect.
The text was updated successfully, but these errors were encountered: