[cairo] Help required with redraw problems
Charles Tuckey
ctuckey at verano.com
Sat Mar 27 21:49:20 PST 2004
Hi David,
We are proceeding with integrating the OpenGL backend with our project.
However, we have run into a problem(s). Note that we are running this on
a Redhat Enteprise Linux 2.1 machine (XFree 4.1.0).
For our purpsoses, we cannot use the method
'cairo_glx_surface_create_for_window' because we want to draw on to a
gtk window's backbuffer which is a pixmap. So we created a clone of
cairo_glx_surface_create_for_window called
cairo_glx_surface_create_for_pixmap and then
glc_glx_surface_create_for_pixmap and created a GLXPixmap using a
glXCreateGLXPixmap() call. On one machine that is running on a VMWare
virtual machine we can draw on to the pixmap and everything works fine.
Another machine (a real one) that has NVIDIA card running NVIDIA X
server and GL implementaion, we get an X error that says:
The program '<unknown>' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadMatch (invalid parameter attributes)'.
(Details: serial 588 error_code 8 request_code 129 minor_code 5)
(Note to programmers: normally, X errors are reported asynchronously;
that is, you will receive the error a while after causing it.
To debug your program, run it with the --sync command line
option to change this behavior. You can then get a meaningful
backtrace from your debugger if you break on the gdk_x_error()
function.)
We tracked down the error to a line that calls glXMakeCurrent().
Do you have any idea what may be causing this error? Or any suggestions
as to what we should be looking at?
Thanks David.
Soorya & Charlie
David Reveman wrote:
> On Thu, 2004-03-25 at 18:02 -0700, Soorya Kuloor wrote:
>
>
>>Hi Carl,
>>
>>We are using cairo on a real-time schematic display application. We have run
>>into some serious problems during redraws. The schematic displays have
>>animated parts that flash with alternating colors when there are problems
>>with the monitored system. When the flashing happens cairo consumes more CPU
>>cycles than is acceptable. We think the only choice for us is to speed up
>>Cairo. We need speed up of atleast by a factor of 2 and we have until Monday
>>to do this :-((.
>>
>>We are using cairo version 0.1.17. We are using the pixman backend and we
>>cannot use Render backend. Would there be any benefits to moving to a newer
>>version? May be the OpenGL backend? Is there any particular part of Cairo or
>>the libpixman, that we can speed up? We do not use any sophisticated
>>capabilities such as transparency or pattern based fills. We use text (a
>>lot).
>
>
> hmm, the OpenGL backend might do it, but text will be the bottleneck
> with the current GL backend patches, especially if you use a lot of it.
> This is because cairo render each glyph using freetype and then transfer
> it to the backend every time a glyph is drawn. A few weeks ago I hacked
> cairo_ft_font.c a little so that it cached glyphs. The results were
> great, text rendering went from the bottleneck to insignificant compared
> to the other drawing operations.
>
> I've put my hacked version of cairo_ft_font.c in
> http://www.cs.umu.se/~c99drn/
> if you like to have a look at it. It's a bit old so I'm not sure it will
> work with the current version of cairo.
>
> The OpenGL backend together with some kind of text hack like mine, would
> give you some great speed improvements. Maybe just a font hack would do
> it for you.
>
> - David
>
--
Charles Tuckey, MSc.
Software Developer
Verano, Inc.
403.299.4765
© Copyright 2004 Verano Inc. owns copyright content of this document
and all attachments unless otherwise indicated. All rights reserved.
Users of Verano Inc. software and tools associated with the software
such as sales & marketing collateral, presentations, user manuals,
training documentation etc. may not republish nor reproduce in whole or
in part the information, in any form or by any means, in any manner
whatsoever without the prior written permission of Verano Inc., and any
such unauthorized use constitutes copyright infringement. An
acknowledgement of the source must be included whenever Verano Inc.
material is copied or published. If you require further information on a
permitted use or license to reproduce or republish any material, address
your inquiry to Verano Inc.Suite 120, 575 West Street, Mansfield,
Massachusetts, 02048-1164. Any infringement of Verano Inc. rights will
result in appropriate legal action. Verano Inc. disclaims any and all
liability for any consequences which may result from any unauthorized
reproduction or use of this Work whatsoever.
More information about the cairo
mailing list