Search Results

Search found 1 results on 1 pages for 'jcayzac'.

Page 1/1 | 1 

  • Convert a gray PNG with alpha to a 1-bit black rectanble with 8-bit alpha

    - by jcayzac
    I use a tool to render LaTeX equations as PNG. The resulting images are in RGBA8888 format. I would like to extract the luminance (grayscale from RGB channels, multiplied by the A channel) as my new alpha channel, set the picture fully black, and save the result in Gray1Alpha8 (G1A8) format. So far I've only managed to get G1A4 or G8A8 but not G1A8. Also, the resulting picture looks like it's not multiplied correctly… convert original.png \ \( -clone 0 -alpha extract \) \ \( -clone 0 -clone 1 -compose multiply -composite \) \ -delete 0 +swap -alpha off -compose copy_opacity -composite -colorspace Gray -depth 4 result.png What am I missing?

    Read the article

1