I use Pixi.js and I want to down-size a big JPEG but the quality of the picture is affected.
I load the picture like this:
this.App = new PIXI.Application({ background: 'black', resizeTo: window, antialias: true })
this.ironing = await PIXI.Assets.load('/ironing.jpg')
this.Container = new PIXI.Container()
this.Painting = PIXI.Sprite.from(this.ironing)
this.App.stage.addChild(this.Container)
this.Container.addChild(this.Painting)
await gsap.to(this.Container, {
width: 2577,
height: 3200,
x: -930,
y: -650,
duration: 0.6
})
In the picture I downloaded, the painting on the left is the pixi rendering with bad quality and on the right there is the preview on a normal image preview app.
You can test my code here: https://virages.io
What's wrong ?
I tried the following:
antialias: true, resolution: window.devicePixelRatio || 1