Results 1 to 2 of 2

Thread: SetPixel

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Jul 2000
    Location
    Liverpool UK
    Posts
    23

    Question

    I've written code to scan a PictureBox (Picture1) from top left to bottom right pixel by pixel. I have used a loop with GetPixel for this an logged RGB values in an array.

    I then want to paint another PictureBox (Picture2) with those values using SetPixel in the same loop based fasion, reading from the array.

    I may modify the values between these two stages, but my problem is with SetPixel - I don't know how to define the pixel I want to set or to set it.

    What I therefore need is a simple bit of code on how to paint a PictureBox using SetPixel with a value from a variable (E.g ColorVAL).

    Any ideas?

  2. #2
    Fanatic Member
    Join Date
    Feb 2000
    Location
    The Netherlands
    Posts
    715
    Don't use Setpixel, Setpixelv is faster.
    And don't post in this forum, it's for feedback on the forums only. Post in 'General VB Questions' or 'Games And Graphics Programming'.
    Oetje
    [email protected]
    93606776
    Visual Basic 6, Windows 2000

    Never pet a burning dog

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width