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

create Direct3D11CaptureFramePool failed #147

Closed
1170300710 opened this issue May 5, 2022 · 1 comment · Fixed by #211
Closed

create Direct3D11CaptureFramePool failed #147

1170300710 opened this issue May 5, 2022 · 1 comment · Fixed by #211
Labels
bug Something isn't working Included in next release

Comments

@1170300710
Copy link

when I use these code:
`
def create_windows_graphics_capture(item: GraphicsCaptureItem):
# Note: Must create in the same thread (can't use a global) otherwise when ran from LiveSplit it will raise:
# OSError: The application called an interface that was marshalled for a different thread
media_capture = MediaCapture()

async def coroutine():
    async_action = media_capture.initialize_async()
    if async_action:
        await async_action
asyncio.run(coroutine())

if not media_capture.media_capture_settings:
    raise OSError("Unable to initialize a Direct3D Device.")
frame_pool = Direct3D11CaptureFramePool.create_free_threaded(
    media_capture.media_capture_settings.direct3_d11_device,
    DirectXPixelFormat.B8_G8_R8_A8_UINT_NORMALIZED,
    1,
    item.size)

`
I got an error:

OSError: [WinError -1072845856] No capture devices are available

how can I fix it?
thans a lot

@Avasam
Copy link
Collaborator

Avasam commented May 6, 2022

I'm assuming you are trying to build/modify/run my fork of the python application yourself? Because none of this is part of AutoSplit at the moment.
If you need help with your environment, I suggest hopping on Discord! https://discord.gg/Qcbxv9y

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Included in next release
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants