Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Save a screenshot in any resolution from the Unity Editor. Useful for making screenshots higher than your monitor's resolution.
using System;
using System.IO;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using UnityEngine;
using UnityEditor;
AUTHOR: Stijn Raaijmakers @bugshake
Custom editor window which will save a screenshot in the play windows resolution.
For example if you have a 1080p screen, but want a 4k screenshot, just set that resolution in the Game window
and the file will be a full 3840x2160 pixels
public class Screenshotter : EditorWindow
List<string> fileHistory = new List<string>();
Vector2 scrollPos =;
public static void ShowWindow()
var win = EditorWindow.GetWindow<Screenshotter>(false, "Screenshotter");
void OnGUI()
string screenshotPath = string.Format("{0}/Screenshots", Application.persistentDataPath);
if (GUILayout.Button("Capture"))
string path = string.Format("{0}/s_{1:yyyy_MM_dd hh_mm_ss}.png", screenshotPath, DateTime.Now);
if (GUILayout.Button("SCREENSHOTS:"))
EditorUtility.RevealInFinder(screenshotPath + "/");
scrollPos = GUILayout.BeginScrollView(scrollPos, GUILayout.Height(100f));
for( int i = fileHistory.Count; i-- > 0;)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment