i'm not sure about how cpu intensive this is, but I use ShareX's built in FFmpeg recorder. the filesizes are very small and the quality is great and adjustable and if you don't want to save the video you can just simply click "abort" while recording to delete it.
little guide for using it:
https://getsharex.com/ you can get ShareX here and to begin recording with it, you'll have to
click "Task settings..." on the left and then click "Screen recorder", after that you can set the FFmpeg FPS (i use 50 cause that's the fps of fangames, but youtube only supports 30 for videos under 720p so use 30 unless you plan to upscale it in a video editor), then click "FFmpeg options". you'll want to download the ffmpeg.exe by pressing the download button if you don't already have it and if you want audio, i recommend using "virtual-audio-capturer" as the audio source. you can ignore the other settings unless you know what you're doing. after that you can exit out the window and exit task settings then press "Capture" on the left and click "Screen recording (FFmpeg)" which opens a region selector and then just make a box around the region you want to record or click the window you want to record (it will automatically find the region x,y for you).
you can also set up a hotkey to press whenever you want to record by going to "Hotkey settings..." on the left and then clicking "Add...". click the "Task" dropdown menu and select "Screen recording (FFmpeg)" and exit the window, back in hotkey settings you can assign a hotkey to it.
NOTE: if you have greenshot, lightshot, puush, gyazo, or any other program that overwrites your printscreen key, sharex will have conflicts with it so it is best to exit that program while having sharex open.