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

WARP sample? #9

Closed
fgasnier71 opened this issue Feb 18, 2022 · 2 comments
Closed

WARP sample? #9

fgasnier71 opened this issue Feb 18, 2022 · 2 comments

Comments

@fgasnier71
Copy link

First, I shall thank you for sharing this.
This library claims to support WARP. However, I failed to find a sample that shows how to generate an image without actually using a device.
Can one actually generate an image from a console application?
All the samples I found seem to rely on render loops and screenshots.

@RolandKoenig
Copy link
Owner

You can take a look into automated tests in SeeingSharp.Tests.
There a MemoryRenderTarget is used to generate an image.

In the TestUtilitites class you see how to force SeeingSharp to use a software rendering device (=WARP). You can do this by calling GraphicsCore.Current.SetDefaultDeviceToSoftware(); after load.

And yes, this all should work from within a console application. I don't testet it myself, but it should behave the same way like in unittest enviornment.

@fgasnier71
Copy link
Author

Thank you!

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

2 participants