How to change Brightness and Contrast using libvlc

This forum is about all development around libVLC.
Ellora
New Cone
New Cone
Posts: 2
Joined: 20 May 2015 13:27

How to change Brightness and Contrast using libvlc

Postby Ellora » 06 Oct 2015 12:43

Hi,

I am using libvlc 2.2.1.
I want to change the brightness and contrast of the video.

Here is the code snippet i am using. Its a C# wrapper to libvlc APIs.
LibVlc.libvlc_video_set_adjust_int(HandlePlayer, libvlc_video_adjust_option_t.libvlc_adjust_Enable, 1);
LibVlc.libvlc_video_set_adjust_float(HandlePlayer, libvlc_video_adjust_option_t.libvlc_adjust_Brightness, value); //Value ranges from 0.0 to 2.0

But i dnt see any change in the brightness.
Please let me know if I am missing any step ?

Just wondering, do we need to set any command line args while creating libvlc instance like video filter or something ?

Thanks

Rémi Denis-Courmont
Developer
Developer
Posts: 15229
Joined: 07 Jun 2004 16:01
VLC version: master
Operating System: Linux
Contact:

Re: How to change Brightness and Contrast using libvlc

Postby Rémi Denis-Courmont » 06 Oct 2015 13:26

It's the other way: you should not pass ANY arguments to libvlc_new(). But those functions might be bugged.
Rémi Denis-Courmont
https://www.remlab.net/
Private messages soliciting support will be systematically discarded

Ellora
New Cone
New Cone
Posts: 2
Joined: 20 May 2015 13:27

Re: How to change Brightness and Contrast using libvlc

Postby Ellora » 07 Oct 2015 08:51

If i try to get the value of brightness after set, i get the correct value. But i dnt see any change in the brightness on the screen.
Even i tried without passing any arguments and facing the same issue.

Please let me know if there is any other way to make it work.
I am not finding any proper steps even after google search.

sherington
Cone that earned his stripes
Cone that earned his stripes
Posts: 491
Joined: 10 Sep 2008 11:57
VLC version: master
Operating System: Linux

Re: How to change Brightness and Contrast using libvlc

Postby sherington » 07 Oct 2015 18:38

Did you try setting the enable value *after* setting the brightness value.


Return to “Development around libVLC”

Who is online

Users browsing this forum: alexsher and 10 guests