DBotThePony — Сегодня, в 4:01
Просто если обе текстуры имеют нормальную прозрачность, но на выходе получается странная вещь, то можно было бы выставить -channel rgb перед -compose
@ -83,11 +83,9 @@ async function size(path) {
|
|||||||
`${root_main}${texture}.png`,
|
`${root_main}${texture}.png`,
|
||||||
'-size', `${width}x${height}`,
|
'-size', `${width}x${height}`,
|
||||||
`xc:rgb(${rgb[0]}, ${rgb[1]}, ${rgb[2]})`,
|
`xc:rgb(${rgb[0]}, ${rgb[1]}, ${rgb[2]})`,
|
||||||
|
'-channel', 'rgb',
|
||||||
'-compose', 'Multiply',
|
'-compose', 'Multiply',
|
||||||
'-composite',
|
'-composite',
|
||||||
`${root_main}${texture}.png`,
|
|
||||||
'-compose', 'copy-opacity',
|
|
||||||
'-composite',
|
|
||||||
`${basedir}/${last.replace(/_colorless/, '').replace(/_white/, '')}_${name}.png`])
|
`${basedir}/${last.replace(/_colorless/, '').replace(/_white/, '')}_${name}.png`])
|
||||||
|
|
||||||
magick.stdout.pipe(process.stdout)
|
magick.stdout.pipe(process.stdout)
|
||||||
@ -131,11 +129,9 @@ async function size(path) {
|
|||||||
`${root_main}${textureColor}.png`,
|
`${root_main}${textureColor}.png`,
|
||||||
'-size', `${width}x${height}`,
|
'-size', `${width}x${height}`,
|
||||||
`xc:rgb(${rgb[0]}, ${rgb[1]}, ${rgb[2]})`,
|
`xc:rgb(${rgb[0]}, ${rgb[1]}, ${rgb[2]})`,
|
||||||
|
'-channel', 'rgb',
|
||||||
'-compose', 'Multiply',
|
'-compose', 'Multiply',
|
||||||
'-composite',
|
'-composite',
|
||||||
`${root_main}${textureColor}.png`,
|
|
||||||
'-compose', 'copy-opacity',
|
|
||||||
'-composite',
|
|
||||||
')',
|
')',
|
||||||
|
|
||||||
`${root_main}${textureOverlay}.png`,
|
`${root_main}${textureOverlay}.png`,
|
||||||
|
Before Width: | Height: | Size: 523 B After Width: | Height: | Size: 523 B |
Before Width: | Height: | Size: 523 B After Width: | Height: | Size: 523 B |
Before Width: | Height: | Size: 523 B After Width: | Height: | Size: 523 B |
Before Width: | Height: | Size: 523 B After Width: | Height: | Size: 523 B |
Before Width: | Height: | Size: 523 B After Width: | Height: | Size: 523 B |
Before Width: | Height: | Size: 523 B After Width: | Height: | Size: 523 B |
Before Width: | Height: | Size: 523 B After Width: | Height: | Size: 523 B |
Before Width: | Height: | Size: 523 B After Width: | Height: | Size: 523 B |
Before Width: | Height: | Size: 523 B After Width: | Height: | Size: 523 B |
Before Width: | Height: | Size: 523 B After Width: | Height: | Size: 523 B |
Before Width: | Height: | Size: 523 B After Width: | Height: | Size: 523 B |
Before Width: | Height: | Size: 523 B After Width: | Height: | Size: 523 B |
Before Width: | Height: | Size: 523 B After Width: | Height: | Size: 523 B |
Before Width: | Height: | Size: 523 B After Width: | Height: | Size: 523 B |
Before Width: | Height: | Size: 523 B After Width: | Height: | Size: 523 B |