• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Linux: using xrandr to display only a segment of the screen
#1
Since I moved pretty much all my retrogaming/emulation activity to linux, I see and learn new things every day...

Yesterday I came across this post:
https://www.reddit.com/r/crtgaming/comme..._on_a_pvm/

I had no idea xrandr was able to feed a predefined segment of a video-output to a monitor.


Code:
xrandr --output VGA1 --scale-from 320x240 --pos 1x1

With my intel GPU I'm using Super Resolutions (mostly 2560x240) and often times I see the output-image is scaled out of proportions when running apps like desktops, emulationstation gui, scummvm etc.

What I did is switching to a super resolution and then run the proposed code to correct the issue.
I was excited to realize that it worked out of the box and the image on my crt looked great.

Now I guess there has to be a drawback using this method - there's got to be, because nobody would use super resolutions instead, right?
Could it be that this method may cause vsync and/or tearing issues?
Since I only tested it with mostly static scenarios like scummvm, maldita castilla for linux and the lxde desktop I haven't seen any issues.

So, let me rephrase the question...
If I was able to create a perfect 320x240@60Hz (or ANY other!) output on my crt with this method, why would I bother to use super resolutions?

I think a super resolution is only needed in the first place to prepare the canvas in terms of height.. Using the segmented output I could create any width I could think of. I have to admit, I have no idea how refresh rates are handled within this concept.

Maybe I'm wrong about this - could somebody please enlighten me?
  Reply
#2
(03-07-2019, 02:52 PM)ArcadeTV Wrote: Since I moved pretty much all my retrogaming/emulation activity to linux, I see and learn new things every day...

Yesterday I came across this post:
https://www.reddit.com/r/crtgaming/comme..._on_a_pvm/

I had no idea xrandr was able to feed a predefined segment of a video-output to a monitor.


Code:
xrandr --output VGA1 --scale-from 320x240 --pos 1x1

With my intel GPU I'm using Super Resolutions (mostly 2560x240) and often times I see the output-image is scaled out of proportions when running apps like desktops, emulationstation gui, scummvm etc.

What I did is switching to a super resolution and then run the proposed code to correct the issue.
I was excited to realize that it worked out of the box and the image on my crt looked great.

Now I guess there has to be a drawback using this method - there's got to be, because nobody would use super resolutions instead, right?
Could it be that this method may cause vsync and/or tearing issues?
Since I only tested it with mostly static scenarios like scummvm, maldita castilla for linux and the lxde desktop I haven't seen any issues.

So, let me rephrase the question...
If I was able to create a perfect 320x240@60Hz (or ANY other!) output on my crt with this method, why would I bother to use super resolutions?

I think a super resolution is only needed in the first place to prepare the canvas in terms of height.. Using the segmented output I could create any width I could think of. I have to admit, I have no idea how refresh rates are handled within this concept.

Maybe I'm wrong about this - could somebody please enlighten me?

This is something I am working with at the moment. Scale from does not give you a native "320x240p" resolution. Instead, it adjust the aspect ration of the frame buffer. So, your physical resolution is still a supper resolution "2560x240p" but with the frame buffer aspect ratio at 11:1 in this instance. I hope this clears things up for you?

The reason for MME4CRT be a lot more advanced in Linux compared to windows, is because there are some many option available to manipulate the OS which are locked down in window. 

The main issue with adding this method is having to rewrite a lot of CRTSwirchRes core as this handles the aspect ratios in RetroArch. Which will brak things if I start changing the physical frame buffer options.
MME4CRT Founder / Developer. 

Cool Lubuntu + MME4CRT  Cool

Please donate to the project

YouTube Channel


  Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)