1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Finished [Updated 10/08/2018] [v2.6] Multiple Displays + Servers, 4K UHD (DirectX 11) Windows Screen Grabber

Discussion in 'Development' started by Sabaat Ahmad, 22 September 2017.

?

DirectX 11 screen capture performs better than DirectX 9?

  1. Yes

    88.9%
  2. No

    11.1%
  1. Rick164

    Rick164 Administrator Staff Member Administrator

    Messages:
    190
    Hardware:
    RPi2, +Arduino, +AtmoOrb
    Will retry with latest version just in case, for Kodi I need to make the HSC addon a bit more configureable and will do that this weekend but current version works like this:

    - Download https://github.com/RickDB/script.hyperionscreencapture/archive/master.zip
    - For manual install unpack to Kodi addon dir:

    C:\Users\<username>\AppData\Roaming\Kodi\addons\script.hyperionscreencapture

    Or install via Kodi addon manager.

    - Make sure the addon is enabled within Kodi and that HSC has API enabled as well.
    - Service.py has the API url hardcoded at the moment to 'http://localhost:29445/API' which should work fine in all cases where they both run locally, but can update in that file if needed (config planned)
    - Make sure you have refresh rate switching enabled in Kodi settings ( => Adjust display refresh rate to match video)

    - Play some 24P content and see if HSC toggles off / on correctly, can sometimes take a few tries to make it "stick" to capture
     
  2. abrenoch

    abrenoch Android Grabber Developer

    Messages:
    89
    Hardware:
    RPi1/Zero, RPi2
    Hey Sabaat, I'm taking my best shot at an android grabber right now and have a quick question for you!

    Assuming you are using the protobuf server to send image data to hyperion, what dimensions would you recommend for the image data? I see in your configs you have an 'image scaling factor', but I have no idea what that actually equates to. Right now I'm looking at 427x240, but I'm not sure if that is too large or not.. I'm getting some opengl errors when trying to render it smaller but I'm not sure if that is a fault of my own or not yet.

    Just trying to get an idea of what you guys are currently doing!

    Thanks!
     
  3. Sabaat Ahmad

    Sabaat Ahmad Member

    Messages:
    52
    Hardware:
    RPi3, +Arduino
    Image scaling factor just mean by how much to divide the screen resolution. So if the image scaling factor is 32 and screen resolution is 1920x1080, then the image sent to Hyperion has the size 60x33. Ideally you would want to send an image close to 60x60. That should be fine for running the ambient lights.
     
  4. sh4dow

    sh4dow New Member

    Messages:
    1
    Hardware:
    RPi1/Zero, RPi2, +Arduino, +nodeMCU/ESP8266
    Hey Sabaat,

    I have connected via HDMI an ultrawide monitor ( 2560x1080 ) to my laptop. I have it as an extended monitor setup. The index of this monitor is 1. The laptop display is 0.

    The thing is that the monitor with index 1 resolution is viewed as 4480x1080 by hyperion screen capture. I think that's because of the extended monitor setup of windows because 2560 + 1920 = 4480.

    upload_2018-5-16_14-14-28.png


    Can it be possible for the hyperion screen capture to grab the actual resolution of the monitor rather than the extended resolution of them both ?

    Thank you.

    Edit: A temporary fix for this would be setting the external monitor with index 1 as the main display. This though will mess with the width of the other monitor.
     
  5. Sabaat Ahmad

    Sabaat Ahmad Member

    Messages:
    52
    Hardware:
    RPi3, +Arduino

    This seems like a bug in the code; can you please open an issue on GitHub for this. I will investigate this.

    I think DX9 capture should still work fine.
     
  6. iiidefconiii

    iiidefconiii Member

    Messages:
    104
    Hardware:
    32/64bit, +Arduino
  7. Sabaat Ahmad

    Sabaat Ahmad Member

    Messages:
    52
    Hardware:
    RPi3, +Arduino
    This issue is now fixed. Please download and install v2.6. Note that if "Check for Updates" option does not work, you will need to manually download the update from GitHub.
     
    • Like Like x 1
  8. bastianum

    bastianum New Member

    Messages:
    13
    Hardware:
    RPi3
    Hi Sabaat,

    I set up Hyperion on a Raspberry Pi 3 with WS2812B LEDs connected, and it works fine from HyperCon on my windows machine. I can send colors through the panel and the LEDs change accordingly.
    I then installed your ScreenGrabber and tried to set it up, but it does not work for me. using Windows 10, I think I configured something wrong.
    Which IP do I need to enter? I connect to my Pi over 192.168.3.116 in HyperCon, the SSH Log says localhost:19444 though.
    As well, is it right that I deactivate the internal and the external grabber in the config.json?
    Thanks for your help in advance.

    Bastian

    EDIT: I am able to get a connection now (with 192.168.2.116:19444), I get a message that the connection is established. As soon as I start a YT video though, I get this error message:

    2018-10-24 13:49:59 [ERROR] [5] HyperionScreenCap.Helper.HyperionTask.StartCapture:0 - HyperionTask[ConfigurationId: 1c49f1]: Exception in screen capture attempt: 1
    System.Exception: Error occured while sending image to server: In die Übertragungsverbindung können keine Daten geschrieben werden: Eine vorhandene Verbindung wurde vom Remotehost geschlossen. ---> System.IO.IOException: In die Übertragungsverbindung können keine Daten geschrieben werden: Eine vorhandene Verbindung wurde vom Remotehost geschlossen. ---> System.Net.Sockets.SocketException: Eine vorhandene Verbindung wurde vom Remotehost geschlossen
    bei System.Net.Sockets.Socket.Send(Byte[] buffer, Int32 offset, Int32 size, SocketFlags socketFlags)
    bei System.Net.Sockets.NetworkStream.Write(Byte[] buffer, Int32 offset, Int32 size)
    --- Ende der internen Ausnahmestapelüberwachung ---
    bei System.Net.Sockets.NetworkStream.Write(Byte[] buffer, Int32 offset, Int32 size)
    bei HyperionScreenCap.ProtoClient.SendRequest(IMessageLite request)
    bei HyperionScreenCap.ProtoClient.SendImageToServer(Byte[] pixeldata, Int32 width, Int32 height)
    bei HyperionScreenCap.Helper.HyperionTask.TransmitNextFrame()
    --- Ende der internen Ausnahmestapelüberwachung ---
    bei HyperionScreenCap.Helper.HyperionTask.TransmitNextFrame()
    bei HyperionScreenCap.Helper.HyperionTask.StartCapture()

    It basically says that there is an error while screen capturing and that no data can be written into the established connection.. any idea what went wrong here?

    Best

    Bastian
     
    Last edited: 24 October 2018
  9. Sabaat Ahmad

    Sabaat Ahmad Member

    Messages:
    52
    Hardware:
    RPi3, +Arduino
    Replied on GitHub