vovavirtual.blogg.se

Color pixel tester
Color pixel tester










color pixel tester

Ī couple of remarks (nitpicking perhaps but i hope you can forgive me for that):ġ) Make sure to map TImage correctly to your picture:Īlthough a TImage component can be used to "map" it's own canvas pixels (read: coordinates) to underlying bitmap, this can be only done when TImage's width and height and location corresponds to dimensions of (loaded) picture/bitmap that is being interrogated for its pixels.

COLOR PIXEL TESTER CODE

Running the procedures you have given me after including the lines in the programme's controls at the top, does not seem to provide a result even though the code compiles quite happily.

color pixel tester

I am writing this to let you know what my level of ignorance is. I would have thought that giving values to X and Y wpould have defined a pixel and that VALR would hold the code for the depth of red in the pixel at that coordinate. Is this what I should be doing? Do I need to supply some specific values for X and Y? This is not clear to me as I am only now trying to get to grips with this graphics stuff.Įssentially what I want to do is to be able to load up either a bitmap, Jpeg, Png or whatever and determine the colour of each defined pixel on that picture. I run the procedures in a sequence of loading the bitmap file and then running the procedure which I expect will provide the colours of the prescribed pixel. at the first statement which accesses a pixel and asks for the color code.- "ValR := ScanData^.rgbRed" What other code do I need. I appreciate your continued help but the new code provides me with the same problem of producing a runtime error of SIG.












Color pixel tester