Welcome to Code Forum!

Join a community that supports you and your coding journey from day one. We strive to be a friendly, supportive community that empowers everyone to be better developers. By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!
  • Guest, before posting your code please take these rules into consideration:
    • It is required to use our BBCode feature to display your code. While within the editor click < / > or >_ and place your code within the BB Code prompt. This helps others with finding a solution by making it easier to read and easier to copy.
    • You can also use markdown to share your code. When using markdown your code will be automatically converted to BBCode. For help with markdown check out the markdown guide.
    • Don't share a wall of code. All we want is the problem area, the code related to your issue.

    GIF shows where to locate </> in the thread and or post editor toolbar.
    To learn more about how to use our BBCode feature, review our "How to post your code into threads" here.

    Thank you, Code Forum.

Python How to implement the output of color data from an image to a table?

maroonlok

New Coder
Good afternoon, there is a picture with a coordinate plane on which the cells are painted in different colors. Can anyone suggest how you can select an area of one cell and output the average color value from this cell separately in the table. At the same time, setting this color, when it enters the table, not the RGB value, but let's say one.

12.png
 
Interesting, but it's rather unclear (at least to me) what exactly you want to do.
"Select an area of one cell" - do you mean you want to click on one of the square cells within the red boundary ?
Then get the average color of that cell ? I assume the average color is the RGB where the R value is the average of the R values of all pixels and son on ?
Can you get a specific pixel from this image ? I don't know how it was generated and am not too familiar with Python graphics.
And then you want to "output the average color value from this cell separately in the table" - what does that mean ? What table ? Why separately ?
"At the same time, setting this color, when it enters the table, not the RGB value, but let's say one." - I have no clue what you are saying here, sorry.
 
Back
Top Bottom