Custom video modes

Discussions about using Linux guests in VirtualBox.

Custom video modes

Postby guyr » 14. May 2007, 07:16

I've got VBox on Windows XP running Gentoo successfully, with additions, using a standard 1024x768 video mode. I've allocated 512 MB to the VM and 32 MB to video. When I change xorg.conf to use 2048x768 (good for software development), upon running startx the window comes up in 1024x768 and the system is corrupted. Clicking icons does nothing, but clicking an inch to the left of an icon will kick off the process. But moving the mouse causes the screen to turn lime green. In other words, the video system is messed up.

In the online help, section 4.3.2 "Video acceleration and high resolution graphics modes" addresses custom resolutions. I tried this approach with no improvement, but of course I had to just guess at the modeline. There is another section in the help, 8.5 "Custom VESA resolutions". I don't know if that is applicable since I'm using the VBox guest additions video driver.

Finally, in the "Using VirtualBox" forum I found a post on custom video sizes. It suggests to use VBoxManage controlvm setvideomodehint. I tried that, again with no more success.

I'd appreciate some guidance. VMWare was able to use this mode with nothing more than changing xorg.conf. Thanks.
Guy Rouillier
guyr
 
Posts: 34
Joined: 14. May 2007, 06:55

Postby michael » 24. May 2007, 14:18

Changing xorg.conf works in the current SVN version (and the upcoming 1.4.0 release) of VBox - you just need to add a new mode, say "2048x768". You don't even have to add a modeline for it. In the 1.3.8 release you can also modify xorg.conf, but you still have to add a modeline. Any modeline entry which xorg considers valid will be fine.
michael
Sun Microsystems, Inc.
 
Posts: 214
Joined: 10. May 2007, 09:46

Postby guyr » 31. May 2007, 08:59

Thank you Michael for the reply. I'll just wait for the 1.4.0 release. I'm liking VBox very much. I've run it side by side with the free Server version of VMWare, and the timesync and video seem to work much better in VBox.
Guy Rouillier
guyr
 
Posts: 34
Joined: 14. May 2007, 06:55

Postby guyr » 10. Jun 2007, 07:41

I just upgraded to 1.40 tonight, and unfortunately custom video modes are still not working for me. I tried it with and without a modeline. Here is what I changed trying to get this to work. In my Screen section of xorg.conf, I have this:

SubSection "Display"
Viewport 0 0
Depth 16
Virtual 2048 768

What I try this, the GUI still comes up on 1024x768 with all the icons in the right place, but things are messed up. The Gentoo initial logo is draw halfway off the screen, and I have to click the mouse about 2 inches to the left of an icon to click it. Both of these are indications that at least part of X thinks the display is wider than VBox is showing.

BTW, here is the modeline I tried. I get the same results with or without it:

Modeline "2048x768" 189 2048 2144 2336 2752 768 769 772 808 +hsync +vsync

Changing the Virtual line is all I've had to do to get custom modes under native Linux or under VMWare. Please let me know what more I need to do. Thanks.
Guy Rouillier
guyr
 
Posts: 34
Joined: 14. May 2007, 06:55

Postby guyr » 13. Jun 2007, 07:28

Ok, I finally got this to work. For the benefit of others who may happen upon this thread, here is what I had to do:

(1) In the Monitor section, create a Modeline for the custom video configuration. Without it, Xorg.0.log complained about something like "undeclared video mode 2048x768". Here's mine:

Modeline "2048x768" 94 2048 2144 2336 2752 768 769 772 808 +hsync +vsync

(2) Then, in the Screen section, in each relevant Display subsection, define the mode you want. I don't know if the Virtual line is required here. I've never used a Modes line either in native Linux or VmWare; I've only ever had to supply the Virtual line to get what I wanted. So I just left the Virtual line there.

SubSection "Display"
Viewport 0 0
Depth 16
Modes "2048x768"
Virtual 1024 768

That's it. When I start up X in this VM, I've now got the custom configuration. VBox brings the screen up every time in 1024x768, so every time I need to stretch it out to it's full dimension. If anyone knows how to tell VBox to start the GUI window in the full guest dimensions, I'd appreciate it.
Guy Rouillier
guyr
 
Posts: 34
Joined: 14. May 2007, 06:55

Postby erik_swe » 26. Jun 2007, 10:41

In 1.4.0 all I had to do was to add my desired resolution to the "Screen" subsection in /etc/X11/xorg.conf for the depth I wanted to use and also change the DefaultDepth to the depth I want to use, and now it starts in full 1680x1050:

Code: Select all   Expand viewCollapse view
Section: "Screen"
      Identifier       "Default Screen"
      Device           "Generic Video Card"
      Monitor          "Generic Moniutor"
      DefaultDepth     24
      Subsection "Display"
                Depth            24
                Modes           "1680x1050" "1024x768" "800x600" "640x480"
       EndSubSection
EndSection
erik_swe
 
Posts: 1
Joined: 26. Jun 2007, 10:27

Postby guyr » 26. Jun 2007, 20:37

The difference may be that my requested size is greater than the width of either of my 2 attached monitors. Yours fits entirely within a single monitor.
Guy Rouillier
guyr
 
Posts: 34
Joined: 14. May 2007, 06:55


Return to Linux Guests

Who is online

Users browsing this forum: No registered users and 11 guests