Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minimized Window not recorded #303

Closed
sandeepmohil opened this issue Jul 2, 2024 · 7 comments
Closed

Minimized Window not recorded #303

sandeepmohil opened this issue Jul 2, 2024 · 7 comments

Comments

@sandeepmohil
Copy link

sandeepmohil commented Jul 2, 2024

While recording a Win Forum Application , Windows Handle is being paased.
this.Handle

Recording works fine only when Window is visible.
When Window is minimized black screen is recorded instead of the app.

Is there a way to fix this ?

Logs :

2024-07-02 16:11:14.044 [DEBUG] [RecordingManager.cpp | ConfigureOutputDir: 144] >> Video output folder is ready
2024-07-02 16:11:14.045 [INFO] [RecordingManager.cpp | operator (): 284] >> Starting recording task
2024-07-02 16:11:14.195 [DEBUG] [OutputManager.cpp | BeginRecording: 103] >> Sink Writer initialized
2024-07-02 16:11:14.199 [DEBUG] [RecordingManager.cpp | StartRecorderLoop: 705] >> Changed Recording Status to Recording
2024-07-02 16:11:17.927 [INFO] [WindowsGraphicsCapture.c | ProcessRecordingTim: 456] >> Restarted Windows Graphics Capture
2024-07-02 16:11:19.877 [DEBUG] [RecordingManager.cpp | EndRecording: 337] >> Stopped recording task
2024-07-02 16:11:19.910 [DEBUG] [RecordingManager.cpp | StartRecorderLoop: 698] >> Recording task was cancelled
2024-07-02 16:11:19.912 [INFO] [OutputManager.cpp | FinalizeRecording: 133] >> Cleaning up resources
2024-07-02 16:11:19.912 [INFO] [OutputManager.cpp | FinalizeRecording: 134] >> Finalizing recording
2024-07-02 16:11:19.914 [DEBUG] [CMFSinkWriterCallback.h | OnFinalize: 18] >> CMFSinkWriterCallback::OnFinalize
2024-07-02 16:11:19.940 [DEBUG] [OutputManager.cpp | FinalizeRecording: 157] >> Shut down IMFMediaSink
2024-07-02 16:11:19.940 [INFO] [RecordingManager.cpp | operator (): 306] >> Exiting recording task
2024-07-02 16:11:19.952 [DEBUG] [ScreenCaptureManager.cpp | CaptureThreadProc:1006] >> Exiting CaptureThreadProc
2024-07-02 16:11:19.960 [DEBUG] [RecordingManager.cpp | SetRecordingComplet: 406] >> Changed Recording Status to Idle
2024-07-02 16:11:19.960 [DEBUG] [RecordingManager.cpp | SetRecordingComplet: 411] >> Sent Recording Complete callback

@sskodje
Copy link
Owner

sskodje commented Jul 2, 2024

Hi! When windows are minimized, they are no longer rendered, so there is unfortunately nothing to record. You got to make sure not to minimize them.

@sskodje sskodje closed this as completed Jul 2, 2024
@SumitKumar-89
Copy link

Hii @sskodje I know that when window is minimized , it is no longer to rendered. So it's become black screen .
But we want to record/ captured wpf application 's screen when window is minimized. Like recording must be continues while windows minimized

So is there any way to fix this ???

@sskodje
Copy link
Owner

sskodje commented Jul 3, 2024

So you want to record a still frame of the window? Try commenting out this line:

m_TextureManager->BlankTexture(pData->Frame, RECT{ 0,0,windowSize.cx,windowSize.cy });

@SumitKumar-89
Copy link

@sskodje , M working on application with dashboard having windows with charts which are being updated dynamically ..This is the reason I want to record the application window screen even when minimized.
So can you help with this scenario?

@sskodje
Copy link
Owner

sskodje commented Jul 3, 2024

When you minimize a window, the operating system stops rendering it to desktop. Therefore it no longer sends any textures to the APIs this library uses to record video. So no, i cannot help you record windows that are minimized.

@SumitKumar-89
Copy link

SumitKumar-89 commented Jul 3, 2024 via email

@aqibbanday
Copy link

So , is there any indirect way to record the screen when the window is minimized.

On Wed, Jul 3, 2024, 2:44 PM Sverre Skodje @.> wrote: When you minimize a window, the operating system stops rendering it to desktop. Therefore it no longer sends any textures to the APIs this library uses to record video. So no, i cannot help you record windows that are minimized. — Reply to this email directly, view it on GitHub <#303 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/ATF6AUCY752D7UP2TB4SDCLZKO6JHAVCNFSM6AAAAABKHITCMSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMBVGUYDSNJYHA . You are receiving this because you commented.Message ID: @.>

No

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants