- Home /
How to take a high-resolution screenshot including OnGUI()?
I have a game with a little OnGUI() interface and I want to take a screenshot that is 8K big, so I can print it on a poster. How can I take a screenshot including the OnGUI()?
Answer by Dave-Carlile · Oct 04, 2015 at 12:48 PM
I guess you could close this for being a duplicate question ( http://answers.unity3d.com/questions/388550/super-high-resolution-camera.html, http://answers.unity3d.com/questions/722773/how-do-i-take-a-super-high-res-screenshot.html ).
You can use Application.CaptureScreenshot and pass in a value for the superSize parameter to have Unity render a frame at a higher resolution (presumably using render to texture) and use that for the screenshot.
You can also create your own camera that renders to a high resolution render texture and do a manual render with that camera. I assume that's pretty much what CaptureScreenshot does. You might need to do this in order to include the GUI.
I disabled anti-aliasing, but when I take a screenshot it get blurry.