-
-
Notifications
You must be signed in to change notification settings - Fork 46.8k
Create change_brightness.py #2126
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Hey @furkanatesli, TravisCI finished with status TravisBuddy Request Identifier: 523a7e50-b00d-11ea-ae15-c70b0cf57a1c |
Hey @furkanatesli, TravisCI finished with status TravisBuddy Request Identifier: b51e5250-b010-11ea-ae15-c70b0cf57a1c |
What is the min and max value of level? Please add these two carriage returns. |
Hey @furkanatesli, TravisCI finished with status TravisBuddy Request Identifier: a7df85a0-b01f-11ea-ae15-c70b0cf57a1c |
from PIL import Image | ||
|
||
|
||
def change_brightness(img: Image, level: float) -> Image: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK... This looks ready to go. Thanks for doing this. Just a few more questions...
- Should level be a float or an int?
- What should be the minimum and maximum allowed values for level?
- 0.0 to 1.0
- -1.0 to 1.0
- 0 to 100
- 0 to 255
- If level is 0 then is the resulting image black?
- If the level is maxed then is the resulting image white or normal?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- float
- -255.0 to 255.0
- No, if level 0 nothing changes.
- If the level is maximized, the resulting image is white
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice contribution! Thanks for doing this.
* Create change_brightness.py * Update change_brightness.py * Update change_brightness.py * Update change_brightness.py * Update change_brightness.py Co-authored-by: Christian Clauss <cclauss@me.com>
Describe your change:
Checklist:
Fixes: #{$ISSUE_NO}
.