This is the mail archive of the cygwin-xfree@cygwin.com mailing list for the Cygwin XFree86 project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Xfree86 is slow! with software like MATLAB



On 27 Sep 2003 at 18:19, Milos Komarcevic wrote:

> On Thu, 2003-09-25 at 23:29, Alexander Gottwald wrote:
> > g.macaulay@niwa.co.nz wrote:
> > 
> > > does not show such a marked difference. One point of difference is that the
> > > Matlab GUI is written entirely in Java, while the other program uses GTK.
> > 
> > With Swing (JFC)? Swing is the most stupid GUI I've ever seen. It draws all
> > components to a local buffer and transfers these buffers as bitmap to the
> > xserver. Most likely this transfer is much slower than a simple "draw a gray
> > rect at 127,86" and "draw text at 129, 88" as GTK and any other "normal" X11
> > does its drawing.

I don't know whether Matlab uses Swing or not. In any case, as Harold 
suggested, the Matlab GUI runs much faster when Cygwin/XFree86 is run in single 
window mode.

Matlab has two graphical bits - the main window where one types commands, 
clicks on buttons and uses menus, etc, and the figure windows that display 
graphs, etc. The first are done using Java while the second are done using 
OpenGL or some other X toolkit (sometimes it looks to be just transferring a 
bitmap from the X client to the X server). The speedup in the first case is 
remarkable when moving from multi to single window mode in Cygwin/XFree86 - 
from taking several seconds to redraw the buttons in the button bar to nearly 
instant. The speedup for the figures is much less - things happen in about 70% 
of the time. 

So in reply to Harold's question:

> So, are the fast apps non-OpenGL and the slow apps OpenGL?,

the answer is no - the slow part of Matlab is not the OpenGL part, but the Java 
part.

Note also that the difference for the figure window drawing (OpenGL) times 
between Cygwin/XFree86 and Xwin32 are minimal, but are quite large for the 
command window (Java) when in multi-window mode.


Regards

Gavin

 
> Don't know much about toolkits, but even xfig (or LyX) for Cygwin runs
> slow locally on Cygwin/XFree86 in comparison to XWin32, so I think
> Harold is 100% on it with the Native GDI engine (no speed issues when
> run in rootless+twm)



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]