Sunday, April 11, 2010

Ubuntu Linux Sketchup using Wine

Update2: I found a much more general solution to the redraw problem.

Update: I'm not sure if that worked or not. I think it improved the situation, but didn't fix the refresh problems entirely.

I've been using Sketchup successfully for quite a while now in Ubuntu linux. The trick was to install the wine PPA in order to get a more recent version of wine than Ubuntu distributes by default.

However, at home I had screen update problems: for instance, when I'd mouse over a face with the push/pull tool, it wouldn't draw in the crosshatching until I left the face.

But today I figured out how to solve the refresh problems, thanks to a comment in the wine appdb entry for sketchup 7. I ran nvidia-settings, then set:

NVIDIA X Server Settings manager checked
Antialiasing Settings - Override Application - Off
Anisotropic Filtering - Override Application - 1x

The next time I started up sketchup, it worked fine.


Anonymous said...

This did not make a difference

Ubuntu Lucid
Wine 1.1.42
Sketchup 7.1696

Anonymous said...

Got rid of the refresh delay by turning off Synk to VBlank.

System -> Administration -> NVIDIA X Server Settings -> OpenGL Settings. Uncheck "Synk to VBlank"

Ubuntu Lucid
Wine 1.2
Sketchup 7.1696

Anonymous said...

"watch -n"... works. Thank you!

Ubuntu 10.04
NVidia 256.44 on ION (ppa:ubuntu-x-swat/x-updates)
Sketchup 7.1.6860
Wine 1.2 (from PPA above)

"Sync to VBlank" (uncheck) or force 1x Anisotropic filtering do not work for me.

256.44 didn't make a difference. I was hoping it would make it unnecessary to run watch, but so far this is the only fix which works. Sketchup is very stable and usable this way.

Anonymous said...

Better late than never? I got this to work by turning Compiz off (Appearance -> Visual Effects -> OFF) and using the watch script idea.

Here was my implementation of a script that launches the watch in an xterm, launches sketchup then kills the xterm on exit. Hope it helps!

#! /bin/bash
# Uses xrefresh launched repeatedly using watch within an iconified xterm
# to force Google Sketchup to redraw every 0.3 seconds...
# Stores the PID and kills the xterm on exit from Sketchup!
xterm -iconic -title "Sketchup Refresher (xterm)" -e "watch -n 0.3 xrefresh -geometry 1x1+500+500" & watchPID=$!
echo $watchPID
env WINEPREFIX="/home/matt/.wine" wine "C:\Program Files\Google\Google SketchUp 8\SketchUp.exe"
kill $watchPID

Anonymous said...

Two additional workarounds (a little cleaner than the 'watch a pixel and
continuously refresh'.

Workaround 1 (slow): Run using the command line:

Workaround 2 (awesome): Run using the command line:
vblank_mode=0 WINEPREFIX="" wine SketchUp.exe

These both absolutely fixed the problem for me of having the screen not update
My configuration:
Sketchup8 installed via WineTricks
Wine 1.5.5
Ubuntu 12.04 64bit
Intel i915 driver (i965 DRI)

Things I tried that *didnt* work:
Using my .drirc to set the vblank_mode to 0
And about a thousand other things.

Anonymous said...

Workaround 2 works fine for me (Lubuntu 12.04, wine 1.5.5, radeon) : excellent !

Sanchez said...

Thanks to the writer of this post and to Anonymous for Workaround 2!
I've made mine work by editing the link on my Desktop, I've added 'vblank_mode=0' to the Exec line of the link, between 'env' and 'WINEPREFIX'.
Just makes it a little nicer!

Installed on Ubuntu 11.10 using Wine 1.4 (Right click > Open with > Wine Windows Program Loader), SketchUp 8, vim for editing the link.

Gunstick said...

easiest solution for me was