Sign in to follow this  
Followers 0
GiulioM

Convert array of colors into an image

4 posts in this topic

Simplified version: my program reads the color of the screen pixels and stores them into a variable or an array. I want it to make some operations on these colors and then generate an image, given those variables or that array. How do I do it?

Example of code:

Dim $pixel[@desktopheight*@desktopwidth+1]
Local $n
For $x=0 to @desktopwidth
   For $y=0 to @desktopheight
      $n=$n+1
      $pixel[$n]=_ColorGetRed(PixelGetColor($x, $y))
      $pixel[$n]=$pixel[$n]+random(0, 255-$pixel[$n]) ; example of manipulating the color
   Next
Next

Share this post


Link to post
Share on other sites



I'm re-answering just to put this topic on the top... No answers in 12 hours, and my question is at the end of the 2nd page D:

Share this post


Link to post
Share on other sites

Edit: problem SOLVED. Waiting for a moderator to close or delete this topic :D

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0