Quantcast
Channel: VBForums - ASP, VB Script
Viewing all articles
Browse latest Browse all 688

Get pixel color by coordinates (PNG)

$
0
0
Dear VB developers,

I used to think that it was impossible to get the pixel color by coordinates when we talk about PNG file, because Microsoft reported that this format is not supported by VBScript. But then I found out about WIA library, which is available on many computers, and even successfully rotated some PNG image. Now it's time to reach out to you.

Name:  ac5d9fa149d2cb41a47aa9f428c0e748.png
Views: 83
Size:  231 Bytes

How to make getPixelColor.vbs, which runs from the command line, picks image's filename and two coordinates as input (for example, image.png 350 15) and then outputs the color as RGB values (for example, 255 0 0)?
Attached Images
 

Viewing all articles
Browse latest Browse all 688

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>