Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. how can i get RGB value from an image

how can i get RGB value from an image

Scheduled Pinned Locked Moved C / C++ / MFC
question
4 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • U Offline
    U Offline
    User 416553
    wrote on last edited by
    #1

    hiiiiiii can anybody telll me how can i pick the RGB value from an image on "onMouseOver event" and how can i show them in edit boxes.

    R 1 Reply Last reply
    0
    • U User 416553

      hiiiiiii can anybody telll me how can i pick the RGB value from an image on "onMouseOver event" and how can i show them in edit boxes.

      R Offline
      R Offline
      rrrado
      wrote on last edited by
      #2

      Try to get your control's device context and use GetPixel()


      rrrado

      A 1 Reply Last reply
      0
      • R rrrado

        Try to get your control's device context and use GetPixel()


        rrrado

        A Offline
        A Offline
        Alexander M
        wrote on last edited by
        #3

        GetRValue, GetBValue and GetGValue are used to get the color from the return value of GetPixel() Don't try it, just do it! ;-)

        U 1 Reply Last reply
        0
        • A Alexander M

          GetRValue, GetBValue and GetGValue are used to get the color from the return value of GetPixel() Don't try it, just do it! ;-)

          U Offline
          U Offline
          User 416553
          wrote on last edited by
          #4

          thanx Alexander canu give me the code so that it will help me alot coz i m a bit new to VC++ its a bit urgent dear. waiting for ur reply thanx again bye regards tahir

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups