MCPCapital / HarmonizeProject

Harmonize Project lets you sync HDMI video with Philips Hue lights using a Raspberry Pi!
231 stars 35 forks source link

Option to increase light's brightness #35

Closed apoorvprecisely closed 1 year ago

apoorvprecisely commented 1 year ago

Wanted to know if there's an option or a parameter one can tweak to increase the intensity of light through the script. It works great ofcourse but I've noticed that the lights are dimmer compared to the app version of hue sync. Apologies if this is something obvious that I'm missing.

bradleydworak commented 1 year ago

That's a good observation regarding the brightness. There is no attempt to increase it from the raw input. I believe it could be normalized to the highest possible setting while keeping the color consistent.

apoorvprecisely commented 1 year ago

@bradleydworak I couldn't find any documentations regarding the calls you're doing. If you can point me to it, I can dig too

bradleydworak commented 1 year ago

@apoorvprecisely One option would be to incorporate a cv2.COLOR_BGR2HSV call on line 385, then maximize V (brightness) to 100, then convert that value to RGB.

apoorvprecisely commented 1 year ago

@bradleydworak this worked for me https://github.com/MCPCapital/HarmonizeProject/pull/36 have a look

bradleydworak commented 1 year ago

This looks fantastic. Any perceived increase in lag time with this processing relative to the video?

On Tue, Jun 20, 2023 at 1:07 PM Apoorv Bhawsar @.***> wrote:

@bradleydworak https://github.com/bradleydworak this worked for me #36 https://github.com/MCPCapital/HarmonizeProject/pull/36 have a look

— Reply to this email directly, view it on GitHub https://github.com/MCPCapital/HarmonizeProject/issues/35#issuecomment-1599187914, or unsubscribe https://github.com/notifications/unsubscribe-auth/AANVBG4DJDJS5XLHRMZSIZTXMHKFBANCNFSM6AAAAAAZMKQVHY . You are receiving this because you were mentioned.Message ID: @.***>

apoorvprecisely commented 1 year ago

I see atleast .5 second delay, but can't say for sure if this is the cause, since my hardware could be different. Also my raspberry pi is old and doesn't have usb 3.0, so not sure if that's the cause

bradleydworak commented 1 year ago

Ok, thx for checking. I like your solution and will test it out soon. This seems to be the most straightforward approach, including the added flag.

On Tue, Jun 20, 2023 at 4:05 PM Apoorv Bhawsar @.***> wrote:

I see atleast .5 second delay, but can't say for sure if this is the cause, since my hardware could be different. Also my raspberry pi is old and doesn't have usb 3.0, so not sure if that's the cause

— Reply to this email directly, view it on GitHub https://github.com/MCPCapital/HarmonizeProject/issues/35#issuecomment-1599426691, or unsubscribe https://github.com/notifications/unsubscribe-auth/AANVBG3JU4YJFNZ4KUS3423XMH7ANANCNFSM6AAAAAAZMKQVHY . You are receiving this because you were mentioned.Message ID: @.***>