HearthSim / Hearthstone-Deck-Tracker

A deck tracker and deck manager for Hearthstone on Windows
https://hsreplay.net/downloads/
4.7k stars 1.11k forks source link

Broadcast Capture #1209

Closed DigitalVortex92 closed 9 years ago

DigitalVortex92 commented 9 years ago

Because of the way that you draw the overlay, there is no way for me or anyone else to capture it. Is it possible to make it capture-able by OBS? For the record, Windows sees the overlay on it's own as well as ShareX (Screenshot Program).

Unless this just happens to be an OBS issues :(

GiggliG commented 9 years ago

You can capture it with OBS. It's a little tricky to set up the first time, but use the Window Capture option not Game Capture.

DigitalVortex92 commented 9 years ago

All it does is capture one large black screen with no information on it. :(

http://stdscatchemall.com/Screenshots/2015-08-11_01-57-23.png

And no, it doesn't work on OBS1 or OBS Multiplatform

Edit: I'm on windows 10 if that screws everything up...

DigitalVortex92 commented 9 years ago

From what I can tell, the issue lies with the fact that the Application uses D3D9. Windows 10 doesn't seem to support it very well, and OBS definitely doesn't work with D3D9 + Windows 10 nicely...

Edit: After some experimenting, I found out that the lack of a window causes it to be uncapturable (on windows 10 at least). I added a window to it and took off "Allow Transparency" and it captures perfectly. Now of course, this ruins the overlay so I have to find a better solution to fix it for Windows 10, but at least I've isolated the issue.

azeier commented 9 years ago

OBS can't capture transparent windows as far as I know.

There a two workarounds currently: 1) You can use monitor capture to just capture game+overlay 2) Enable options > overlay > deck windows, you can capture those

DigitalVortex92 commented 9 years ago

That's what I was using, but I wanted the overlay itself because of how nice it looks personally. So I modified the original app code and added a compatibility window. Basically, all it does is sit behind Hearthstone. It's a full window so it captures, and you can chroma key the black caused by the lack of texture, or if I really wanted to, I could add a real color to chroma out. It work for what it needs to and it doesn't add much extra memory usage. What I might do is actually add a full implementation of it with a toggle in the settings, then make a pull request with it. For now, it's getting late, and until I know it's stable, i'm gonna keep it personal.]

In terms of OBS and transparent windows, it has support for PNG's, alpha backgrounds on webpages and such, but the issue at the root is that the window is a WindowStyle.None window which causes the capture issue. It SHOULD capture the text with a black screen if that's the case (from the way I see it), but it doesn't.

azeier commented 9 years ago

Oh if you could make that into a PR, that would be awesome! :)

DigitalVortex92 commented 9 years ago

I've decided to go down the plugin route for this. I introduced the idea to Kripparrian (where I did integrate it), but he stuck with the Player/Opponent Window, so now, I'm making it into a plugin :)

I'm also doing something no one else has (see screenshot below): Note the extra TreeViewItem... http://stdscatchemall.com/Screenshots/Hearthstone_Deck_Tracker_2015-08-15_12-50-28.png

It was a PAINNNNN at first to capture the TreeView, but once i found a method to do it, it's now super easy :D

azeier commented 9 years ago

A plugin is a even better solution, yea! The options item is neat :D.

Let me know if you need help with anything!

DigitalVortex92 commented 9 years ago

At this point, I'm just trying to think of what other settings to add to it. Since i made a direct copy of OverlayWindow (in order to preserve functionality, and change a few settings to accommodate the window size and a couple of other things), it maintains all the same functionality as you change the overlay settings. So I can't really think of anything other than what I've got...

DigitalVortex92 commented 9 years ago

Plugin is added to available plugins page!

DigitalVortex92 commented 9 years ago

I just realized that I forgot to request that you update MahApps to the most recent version. There were some issues compiling with the old version when I made the program. The latest version works fine with the application :) My plugin won't show up in the plugins list because it's running on the newer version :(

azeier commented 9 years ago

Awesome!

As far as I can see, MahApps is up to date. Their latest release (github and nuget) was 1.1.2 on march 1st.

DigitalVortex92 commented 9 years ago

Yeah, it's on 1.1.2, and the issue seems to have gone away. It seemed like it was a bug with the project or something, don't really know. It's gone. I'm trying to determine why it won't show up in the plugins list, and will update the wiki as soon as I fix it!

DigitalVortex92 commented 9 years ago

K. I've officially stopped bouncing back and fourth on this. It's working now :D

kerberosargos commented 7 years ago

Hi I need help for capturing WPF transparent Window? When I trying to capture window I am getting black background, is it possible with OBS Classic or not?

My OS is Window 7.

Thank you in advance.

DigitalVortex92 commented 7 years ago

The project was halted very soon after it's creation. I am unable to help you due to the nature of the upgrades the main program has seen. I may possibly work on this in the future, but as of right now, it is dead.

On Feb 7, 2017 12:14 PM, "Kerberos" notifications@github.com wrote:

Hi I need help for capturing WPF transparent Window? When I trying to capture window I am getting black background, is it possible with OBS Classic or not?

My OS is Window 7.

Thank you in advance.

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub https://github.com/HearthSim/Hearthstone-Deck-Tracker/issues/1209#issuecomment-278070133, or mute the thread https://github.com/notifications/unsubscribe-auth/AHsPL2mRlTNRBMAsg2GymvX8XXuoi8a-ks5raKaMgaJpZM4FpPAi .

riQQ commented 7 years ago

@kerbooo have you tried this https://github.com/HearthSim/Hearthstone-Deck-Tracker/wiki/Streaming-Instructions?