fix excessive initialization because of pixel ratio multiplication

This commit is contained in:
Pavel Dobryakov
2019-08-07 12:25:43 +03:00
parent 4223ee0023
commit 2d86a9f0b8

View File

@@ -11,7 +11,7 @@ let config = {
PRESSURE: 0.8,
PRESSURE_ITERATIONS: 20,
CURL: 30,
SPLAT_RADIUS: 0.4,
SPLAT_RADIUS: 0.25,
SPLAT_FORCE: 6000,
SHADING: true,
COLORFUL: true,
@@ -1348,5 +1348,5 @@ function getTextureScale (texture, width, height) {
function scaleByPixelRatio (input) {
let pixelRatio = window.devicePixelRatio || 1;
return input * pixelRatio;
return Math.floor(input * pixelRatio);
}