Dual screen how to force hyperion-x11 to use only a screen

  • Hi,


    First of all thank you for this project it really awesome.


    I have a dual screen, is it possible to executing hyperion-x11 only on one specific screen ?


    Presently my Kodi is parameter with "mode display" defined to "fullscreen". With this setting some leds use the colors of my second screen where kodi is not running.


    For that the LEDs are working properly I am obliged to check the option in Kodi "blank other displays".


    I search a way of keep my second screen and to force hyperion-x11 to use the resolution of my screen where kodi is running for the control of leds.


    In the logs I see the following line :
    X11GRABBER INFO: Update of screen resolution: [3360x1080] => [1920x1080]


    Is it possible to force x11grabber of use only a screen keeping my dual screen functional ?


    thank you in advance,

  • Thank you for your reply.


    I think I found a trick, it is certainly not very clean but it's working.


    I have compiled Hyperion by editing the file X11Grabber.cpp in the directory ./libsrc/grabber/x11


    I replace in this file that condition :
    if (_screenWidth == unsigned(_windowAttr.width) && _screenHeight == unsigned(_windowAttr.height))
    by
    if (_screenWidth == unsigned(1920) && _screenHeight == unsigned(1080))

    Then, I redefined the variables following :
    _screenWidth = 1920; // _windowAttr.width;
    _screenHeight = 1080; // _windowAttr.height;


    I do not have enough skills in this language to do something more clean.


    If someone have another way it interests me :)

  • Hi,


    Can you start the hyperiond manually from the command line ?


    Yes, I start hyperiond and hyperion-x11 without error from my terminal.
    hyperion-x11 takes the resolution as i have defined
    X11GRABBER INFO: Update of screen resolution: [0x0] => [1920x1080]


    Does it honor the DISPLAY environment variable ?


    Yes, my variable $DISPLAY has the value :0.0

    Do you have multiple screens or multiple displays ?


    I'm not very sure to know the exact difference. I use xmonad as window manager and I run my "dual screen" with xrandr :
    xrandr --output HDMI-1 --mode 1920x1080 && xrandr --output DVI-I-1 --pos 0x0 --mode 1440x900 --rate 75.0 --right-of HDMI-1 &


    I hope my answers are enough clear

    • Offizieller Beitrag

    Change the :0.0 to ":0.1" if you have a second monitor.
    If you have multiple X sessions running, you can use :1.0, :2.0, etc to start hyperion-x11 on a specific session.
    Another Option is to use the crop Parameter from hyperion-x11.


    http://stackoverflow.com/a/1210332
    http://gerardnico.com/wiki/linux/display

  • Thank you for your help.


    Unfortunately my variable $DISPLAY is the same on my two monitors.


    However I did not know that Hyperion-x11 had of the parameters. I tried the command "man hyperion-x11" but I forgot to try "hyperion-x11 --help". :p


    I will tried to have something more clean with the --crop parameters, thank you.

    • Offizieller Beitrag

    To see the result of the crop parameters use the screenshot paramter.


    Example: "hyperion-x11 --crop-top 100 --screenshot -s 1"


    "--crop-top 100" crop 100 pixels from the top of the screen
    "--screenshot" create a screenshot.png file in the folder of hyperion-x11 and
    "-s 1" set the Decimation factor for the output size of the Image.

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!