graphics!!

2006-05-03 Thread ferri_marllo


 Hello!!
 I need help about creating graphics...i want to represent points into a
graphic, but i want to can interact with them too,so i need to click on them
and see in the satatus bar what're the coordenates,i need to can delete them,
and more things.
 I'm trying with gdk,but the problem is that i don't know how to interact with
 them,i only can represent them.
So,can anyone suggest me how to do it??
Thanks a lot!

___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: graphics!!

2006-05-03 Thread Ivan N. Zlatev
On Wed, 2006-05-03 at 12:25 +0200, [EMAIL PROTECTED] wrote:
> 
>  Hello!!
>  I need help about creating graphics...i want to represent points into a
> graphic, but i want to can interact with them too,so i need to click on them
> and see in the satatus bar what're the coordenates,i need to can delete them,
> and more things.
>  I'm trying with gdk,but the problem is that i don't know how to interact with
>  them,i only can represent them.
> So,can anyone suggest me how to do it??
> Thanks a lot!

I think you may need to use a canvas. For example:
http://developer.gnome.org/doc/API/2.0/libgnomecanvas/index.html
http://www.dachaplin.dsl.pipex.com/goocanvas/

-- 
Ivan N. Zlatev

Web: http://www.i-nZ.net
GPG Key: http://files.i-nz.net/i-nZ.asc
"It's all some kind of whacked out conspiracy."
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Re: graphics!!

2006-05-03 Thread Ivan N. Zlatev
On Wed, 2006-05-03 at 12:25 +0200, [EMAIL PROTECTED] wrote:
> 
>  Hello!!
>  I need help about creating graphics...i want to represent points into a
> graphic, but i want to can interact with them too,so i need to click on them
> and see in the satatus bar what're the coordenates,i need to can delete them,
> and more things.
>  I'm trying with gdk,but the problem is that i don't know how to interact with
>  them,i only can represent them.
> So,can anyone suggest me how to do it??
> Thanks a lot!

I think you may need to use a canvas. For example:
http://developer.gnome.org/doc/API/2.0/libgnomecanvas/index.html
http://www.dachaplin.dsl.pipex.com/goocanvas/

-- 
Ivan N. Zlatev

Web: http://www.i-nZ.net
GPG Key: http://files.i-nz.net/i-nZ.asc
"It's all some kind of whacked out conspiracy."
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Re: graphics!!

2006-05-03 Thread Ivan N. Zlatev
On Wed, 2006-05-03 at 12:25 +0200, [EMAIL PROTECTED] wrote:
> 
>  Hello!!
>  I need help about creating graphics...i want to represent points into a
> graphic, but i want to can interact with them too,so i need to click on them
> and see in the satatus bar what're the coordenates,i need to can delete them,
> and more things.
>  I'm trying with gdk,but the problem is that i don't know how to interact with
>  them,i only can represent them.
> So,can anyone suggest me how to do it??
> Thanks a lot!

I think you may need to use a canvas. For example:
http://developer.gnome.org/doc/API/2.0/libgnomecanvas/index.html
http://www.dachaplin.dsl.pipex.com/goocanvas/

-- 
Ivan N. Zlatev

Web: http://www.i-nZ.net
GPG Key: http://files.i-nz.net/i-nZ.asc
"It's all some kind of whacked out conspiracy."
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Re: graphics!!

2006-05-03 Thread Ivan N. Zlatev
On Wed, 2006-05-03 at 12:25 +0200, [EMAIL PROTECTED] wrote:
> 
>  Hello!!
>  I need help about creating graphics...i want to represent points into a
> graphic, but i want to can interact with them too,so i need to click on them
> and see in the satatus bar what're the coordenates,i need to can delete them,
> and more things.
>  I'm trying with gdk,but the problem is that i don't know how to interact with
>  them,i only can represent them.
> So,can anyone suggest me how to do it??
> Thanks a lot!

I think you may need to use a canvas. For example:
http://developer.gnome.org/doc/API/2.0/libgnomecanvas/index.html
http://www.dachaplin.dsl.pipex.com/goocanvas/

-- 
Ivan N. Zlatev

Web: http://www.i-nZ.net
GPG Key: http://files.i-nz.net/i-nZ.asc
"It's all some kind of whacked out conspiracy."
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Re: graphics!!

2006-05-03 Thread Ivan N. Zlatev
On Wed, 2006-05-03 at 12:25 +0200, [EMAIL PROTECTED] wrote:
> 
>  Hello!!
>  I need help about creating graphics...i want to represent points into a
> graphic, but i want to can interact with them too,so i need to click on them
> and see in the satatus bar what're the coordenates,i need to can delete them,
> and more things.
>  I'm trying with gdk,but the problem is that i don't know how to interact with
>  them,i only can represent them.
> So,can anyone suggest me how to do it??
> Thanks a lot!

I think you may need to use a canvas. For example:
http://developer.gnome.org/doc/API/2.0/libgnomecanvas/index.html
http://www.dachaplin.dsl.pipex.com/goocanvas/

-- 
Ivan N. Zlatev

Web: http://www.i-nZ.net
GPG Key: http://files.i-nz.net/i-nZ.asc
"It's all some kind of whacked out conspiracy."
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Re: graphics!!

2006-05-08 Thread Juhana Sadeharju

>I think you may need to use a canvas. For example:
>http://developer.gnome.org/doc/API/2.0/libgnomecanvas/index.html
>http://www.dachaplin.dsl.pipex.com/goocanvas/

Do they have a graph widget? Or are they more primitive?

I need such a widget in audio apps:
(1) Envelopes drawn over the audio waveform widget.
(2) Frequency response curves of multiple parametric filters
drawn in one canvas.
(3) Control envelopes.

Much of the stuff what can be seen in VST plugins, in Absynth
(specially envelopes), Waves' plugins, etc. They look nice too
unlike what I most see here.

Does GTK canvases provide transparency? What programs uses the
canvases? I might want see how they look like.

With gtkglext/opengl all seems to be eventually simpler.
Multiple "widgets" can be combined by using suitable transparency
and depth coordinates. Decorations are done easily, e.g., by
modeling objects in 3D. But then I cannot use the GTK widgets
indistinctly. Interaction with the opengl objects comes a problem
as well, making it tempting to use, e.g., OSG (openscenegraph.org).
But that is a large software and written with C++, which could be
a problem if I want code in C.

How would GTK's Cairo integration help? If at all.

Juhana
-- 
  http://music.columbia.edu/mailman/listinfo/linux-graphics-dev
  for developers of open source graphics software
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: graphics!!

2006-05-08 Thread Michael L Torrie
On Mon, 2006-05-08 at 22:27 +0300, Juhana Sadeharju wrote:
> >I think you may need to use a canvas. For example:
> >http://developer.gnome.org/doc/API/2.0/libgnomecanvas/index.html
> >http://www.dachaplin.dsl.pipex.com/goocanvas/
> 
> Do they have a graph widget? Or are they more primitive?

No. GTK only provides primitives.  There have been several graph widgets
implemented using GTK.  

> 
> I need such a widget in audio apps:
> (1) Envelopes drawn over the audio waveform widget.
> (2) Frequency response curves of multiple parametric filters
> drawn in one canvas.
> (3) Control envelopes.

All of these things would need to be implemented using primitives.  GTK
is just a GUI toolkit, not a domain-specific toolbox.  Audacity (which
uses wxWidgets not GTK) implemented their own widgets for dealing with
waveform graphs and selections and things.

> 
> Much of the stuff what can be seen in VST plugins, in Absynth
> (specially envelopes), Waves' plugins, etc. They look nice too
> unlike what I most see here.
> 
> Does GTK canvases provide transparency? What programs uses the
> canvases? I might want see how they look like.

There is no GTK canvas officially yet.  There are several
implementations of canvases for GTK including gnome-canvas, foo-canvas,
etc.  They vary in purpose and function.

> 
> With gtkglext/opengl all seems to be eventually simpler.
> Multiple "widgets" can be combined by using suitable transparency
> and depth coordinates. Decorations are done easily, e.g., by
> modeling objects in 3D. But then I cannot use the GTK widgets
> indistinctly. Interaction with the opengl objects comes a problem
> as well, making it tempting to use, e.g., OSG (openscenegraph.org).
> But that is a large software and written with C++, which could be
> a problem if I want code in C.
> 
> How would GTK's Cairo integration help? If at all.

Using Cairo do do you drawing of wave forms, envelopes, etc is a good
idea if Cairo is fast enough to do what you need to.  Certainly it seems
to me that a waveform graph, envelopes, etc would be well-suited to a
vector-drawing API.

> 
> Juhana

___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Simple vector graphics printing example?

2013-01-25 Thread Satz Klauer
Hi,

I plan to print out some vector data using the GTK printing system.

I already found the API description but what I'm missing is a general
overview that describes what has to be used in which order to send such
graphics to a printer.

So my question: is there a simple printing example code or a tutorial
available somewhere that describes how to use the printing functions?
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: graphics!! - Evolution spam - not mine!

2006-05-03 Thread Ivan N. Zlatev
On Wed, 2006-05-03 at 11:45 +0100, Ivan N. Zlatev wrote:
> On Wed, 2006-05-03 at 12:25 +0200, [EMAIL PROTECTED] wrote:
> > 
> >  Hello!!
> >  I need help about creating graphics...i want to represent points into a
> > graphic, but i want to can interact with them too,so i need to click on them
> > and see in the satatus bar what're the coordenates,i need to can delete 
> > them,
> > and more things.
> >  I'm trying with gdk,but the problem is that i don't know how to interact 
> > with
> >  them,i only can represent them.
> > So,can anyone suggest me how to do it??
> > Thanks a lot!
> 
> I think you may need to use a canvas. For example:
> http://developer.gnome.org/doc/API/2.0/libgnomecanvas/index.html
> http://www.dachaplin.dsl.pipex.com/goocanvas/
> 

My greatest apologies for my previous e-mail being sent 5 (!!!) times,
but it's not my fault. Apparently Evolution decided to spam you :S I
really hope this e-mail won't reach the mailing list five times as the
previous did...

-- 
Ivan N. Zlatev

Web: http://www.i-nZ.net
GPG Key: http://files.i-nz.net/i-nZ.asc
"It's all some kind of whacked out conspiracy."

___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


GRAPHICS INTERFACE with GTK 3 - VIDEO

2012-08-17 Thread Mariano Gaudix
Hello ...  How I can that  make a window always appears in the
display as a MENU? . I am creating a GRAPHICS INTERFACE
with GTK 3 and VALA .I am using WINDOW-POPUP  as  menu
 ..  and   i need   that  this  always appears in the display  .



See  video



http://www.youtube.com/watch?v=4FxRx84lid8
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


GRAPHICS INTERFACE with GTK 3 - VIDEO

2012-08-17 Thread Mariano Gaudix
Hello ...  How I can that  make a window always appears in the
display as a MENU? . I am creating a GRAPHICS INTERFACE
with GTK 3 and VALA .I am using WINDOW-POPUP  as  menu
 ..  and   i need   that  this  always appears in the display  .



See  video


http://www.youtube.com/watch?v=4FxRx84lid8
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Hardware accelerated 2D graphics (with gtk-osx)

2010-07-27 Thread John Emmas
Firstly, please let me apologise if this isn't the right mailing list for 
gtk-osx queries.  I don't remember ever seeing an enquiry here about gtk-osx - 
so please feel free to direct me somewhere else if this isn't an appropriate 
list.

I'm a C++ programmer working on a cross-platform application that will 
eventually run on Linux, Windows and Mac.  It's a similar product to Pro Tools, 
Logic, Cuebase etc.  The app has a "scrolling" display, similar to a multitrack 
tape (as is common with this kind of app).  Graphical window elements are 
provided by the GTK+ library on all 3 platforms - gtk-x11 under Linux, 
gtk-win32 under Windows and gtk-osx under OS-X.

Under Windows and Linux the (2D) scrolling display is smooth.  But under OS-X 
it's horribly jerky and has a very 'klunky' look to it.  I happen to be viewing 
it on a Mac Mini but other people have seen the same effect with more powerful 
machines.  It isn't a processor issue because even with my lowly Mac Mini, the 
cpu usage rarely gets higher than about 30 percent.

Today I found this article on Wikipedia,  I think it might explain the sluggish 
timeline scrolling that we're seeing under OS-X:-

http://en.wikipedia.org/wiki/Quartz_Compositor

If I'm reading it correctly, OS-X uses a compositing engine called Quartz 
Compositor which seems to consist of Quartz Extreme (for 3D graphics) and 
QuartzGL (formerly called Quartz2D Extreme) for 2D graphics.  Apparently, 
Quartz Compositor is the only process that's allowed to access the graphics 
frame buffer directly. So other technologies (QuartzGL / OpenGL  / Quicktime 
etc) need to go through it.  Thus, to utilise hardware acceleration, gtk-osx 
would presumably need to make use of a compatible technology, such as one of 
those.

My guess is either that gtk-osx isn't using any technology that's compatible 
with Quartz Compositor - or if it is, it's maybe using QuartzGL.  
Disappointingly, QuartzGL DISABLES 2D hardware acceleration by default and I'm 
wondering if this might explain the poor performance that we observe under 
OS-X?  As I said earlier, Windows and Linux are both fine.

Is there anyone here who can shed any light on this?  Or suggest another forum 
where I'll be able to find some answers?  Many thanks.

John
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Hardware accelerated 2D graphics (with gtk-osx)

2010-07-28 Thread John Emmas
This morning I've come across this mailing list which has got me confused:-

http://sourceforge.net/mailarchive/forum.php?forum_name=gtk-osx-users

Up until now I'd assumed that gtk-osx was produced / administered by gnome.org 
but the above mailing list makes it look like it's possibly an independent 
project.  Should I have posted my question there instead of here?  Or are there 
two different gtk-osx projects?

John
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Hardware accelerated 2D graphics (with gtk-osx)

2010-08-01 Thread Kristian Rietveld
On Jul 28, 2010, at 9:15 AM, John Emmas wrote:

> This morning I've come across this mailing list which has got me confused:-
> 
> http://sourceforge.net/mailarchive/forum.php?forum_name=gtk-osx-users

My understanding is that this mailing list is for discussion of gtk+ on osx as 
well as certain subprojects such as global menu bar support, GTK+ framework 
packaging, etc.

> Up until now I'd assumed that gtk-osx was produced / administered by 
> gnome.org but the above mailing list makes it look like it's possibly an 
> independent project.  Should I have posted my question there instead of here? 
>  Or are there two different gtk-osx projects?

The most up to date GTK+ OSX backend is in GNOME git, bugs are tracked on 
bugzilla.gnome.org.


regards,

-kris.

___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Hardware accelerated 2D graphics (with gtk-osx)

2010-08-01 Thread Kristian Rietveld
On Jul 27, 2010, at 10:49 AM, John Emmas wrote:
> Under Windows and Linux the (2D) scrolling display is smooth.  But under OS-X 
> it's horribly jerky and has a very 'klunky' look to it.  I happen to be 
> viewing it on a Mac Mini but other people have seen the same effect with more 
> powerful machines.  It isn't a processor issue because even with my lowly Mac 
> Mini, the cpu usage rarely gets higher than about 30 percent.

On my Macs the GTK+ graphics rendering is pretty fast.  There might have been 
issues in the past, but recent GTK+ releases should be pretty good.

That said, some people do see performance issues that cannot be reproduced on 
other machines, for example https://bugzilla.gnome.org/show_bug.cgi?id=615917.  
What exactly is causing this and whether this is hardware-specific still has to 
be found out.  We need to collect GTK+ version in use and hardware details in 
these cases.

> My guess is either that gtk-osx isn't using any technology that's compatible 
> with Quartz Compositor - or if it is, it's maybe using QuartzGL.  
> Disappointingly, QuartzGL DISABLES 2D hardware acceleration by default and 
> I'm wondering if this might explain the poor performance that we observe 
> under OS-X?  As I said earlier, Windows and Linux are both fine.

GTK+ OSX does all drawing using CoreGraphics, this should be 
hardware-accelerated whenever possible.


regards,

-kris.

___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Hardware accelerated 2D graphics (with gtk-osx)

2010-08-01 Thread John Emmas

On 1 Aug 2010, at 21:41, Kristian Rietveld wrote:

> On Jul 28, 2010, at 9:15 AM, John Emmas wrote:
> 
>> This morning I've come across this mailing list which has got me confused:-
>> 
>> http://sourceforge.net/mailarchive/forum.php?forum_name=gtk-osx-users
> 
> My understanding is that this mailing list is for discussion of gtk+ on osx 
> as well as certain subprojects 
> 

Thanks Kristian.  I found out later that the other mailing list is for 
questions relating to GTK+ version 1.  It seems as if version 1 is still being 
developed alongside version 2 but I'm not sure why.

Anyway, I've managed to find out that under OS-X, hardware acceleration is only 
available for certain supported chipsets, which seems reasonable enough - but 
even when it's supported, only 3D acceleration is enabled by default.  
Bizarrely, 2D acceleration is disabled by default and needs to be enabled using 
something called that Quartz Debug Application.  The worrying thing is that 
this probably makes sense to someone at Apple  :-(
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Hardware accelerated 2D graphics (with gtk-osx)

2010-08-01 Thread Olivier Sessink

On 07/28/2010 09:15 AM, John Emmas wrote:

This morning I've come across this mailing list which has got me
confused:-

http://sourceforge.net/mailarchive/forum.php?forum_name=gtk-osx-users

 Up until now I'd assumed that gtk-osx was produced / administered by
gnome.org but the above mailing list makes it look like it's possibly
an independent project.  Should I have posted my question there
instead of here?  Or are there two different gtk-osx projects?


That list focuses on more tight integration on the Mac OSX desktop. For 
example having the menu on top of the screen and not in your 
application, opening your app from the finder, etc. There's also quite 
some OSX and GTK knowledge there, so it's a good list to join if you're 
going to do some GTK app programming on a mac.


Olivier
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Hardware accelerated 2D graphics (with gtk-osx)

2010-08-06 Thread John Emmas
On 1 Aug 2010, at 21:49, Kristian Rietveld wrote:

> On Jul 27, 2010, at 10:49 AM, John Emmas wrote:
>> Under Windows and Linux the (2D) scrolling display is smooth.  But under 
>> OS-X it's horribly jerky and has a very 'klunky' look to it.  I happen to be 
>> viewing it on a Mac Mini but other people have seen the same effect with 
>> more powerful machines.  It isn't a processor issue because even with my 
>> lowly Mac Mini, the cpu usage rarely gets higher than about 30 percent.
> 
> On my Macs the GTK+ graphics rendering is pretty fast.  There might have been 
> issues in the past, but recent GTK+ releases should be pretty good.
> 
> That said, some people do see performance issues that cannot be reproduced on 
> other machines, for example 
> https://bugzilla.gnome.org/show_bug.cgi?id=615917.  What exactly is causing 
> this and whether this is hardware-specific still has to be found out.  We 
> need to collect GTK+ version in use and hardware details in these cases.
> 
>> My guess is either that gtk-osx isn't using any technology that's compatible 
>> with Quartz Compositor - or if it is, it's maybe using QuartzGL.  
>> Disappointingly, QuartzGL DISABLES 2D hardware acceleration by default and 
>> I'm wondering if this might explain the poor performance that we observe 
>> under OS-X?  As I said earlier, Windows and Linux are both fine.
> 
> GTK+ OSX does all drawing using CoreGraphics, this should be 
> hardware-accelerated whenever possible.
> 

This morning I installed Apple's developer tools which include a utility called 
the Quartz Debug Application.  This allows you to enable and disable certain 
graphical features and see what affect they have on your program's graphics 
performance.  The first thing I noticed was that the option to disable 2D 
hardware acceleration seems to be working the wrong way around.  Checking the 
box to disable 2D acceleration initially had no effect.  Unchecking it though 
(i.e. theoretically enabling acceleration) made my scrolling performance 
considerably worse.  My impression is that the checkbox seems to be wrongly 
worded which might explain why so many people believe that 2D hardware 
acceleration is disabled by default.  Either that or the wikipedia article is 
right and enabling 2D hardware acceleration on a Mac can actually degrade the 
graphics performance (!).

Whatever the truth of the matter, one option that made a huge improvement to my 
canvas scrolling was the setting called "Autoflush drawing".  I assume that 
this must execute all drawing operations immediately, instead of trying to 
intelligently queue them.  So it looks as if some judiciously placed flush 
calls might be all I need to improve the problem of my poor GTK canvas 
scrolling.

Before I go around adding flush calls willy-nilly, I just wondered if there's 
any API call in GTK/GDK that might already "auto flush" my canvas drawing 
operations automatically?  If so, I'd like to experiment with it.  If not, I'll 
just have to figure out some sensible places in my code where I can flush the 
drawing operations.

Thanks,

John
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Hardware accelerated 2D graphics (with gtk-osx)

2010-08-08 Thread John Emmas

On 1 Aug 2010, at 21:49, Kristian Rietveld wrote:

> 
> GTK+ OSX does all drawing using CoreGraphics, this should be 
> hardware-accelerated whenever possible.
> 

>From what I've been able to tell, CoreGraphics eventually ends up using 
>QuartzGL for 2D imaging and acceleration.  QuartzGL however seems to be buggy, 
>unfinished and badly written.  On my system (and I suspect most other Macs) 
>enabling hardware acceleration for QuartzGL actually worsens 2D graphics 
>performance rather than enhancing it.

So another option might be to use gtk-x11 in the Mac build, instead of gtk-osx. 
 Obviously this would require an X server to be installed but I don't think 
that's too difficult on a Mac.  The question is whether or not X (under OS-X) 
also uses QuartzGL or whether it interfaces with Quartz Compositor directly (or 
via some alternative technology, such as OpenGL).  I'm assuming there must be 
an interface to Quartz Compositor at some stage.

Anyone know where I could find out some more information about X server for 
OS-X?

John
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Hardware accelerated 2D graphics (with gtk-osx)

2010-08-08 Thread Kristian Rietveld
On Aug 8, 2010, at 9:32 PM, John Emmas wrote:
> On 1 Aug 2010, at 21:49, Kristian Rietveld wrote:
> 
>> 
>> GTK+ OSX does all drawing using CoreGraphics, this should be 
>> hardware-accelerated whenever possible.
>> 
> 
> From what I've been able to tell, CoreGraphics eventually ends up using 
> QuartzGL for 2D imaging and acceleration.  QuartzGL however seems to be 
> buggy, unfinished and badly written.  On my system (and I suspect most other 
> Macs) enabling hardware acceleration for QuartzGL actually worsens 2D 
> graphics performance rather than enhancing it.

What hardware and OS revision are you using?  Do you experience this just in 
your canvas or in other GTK+ applications as well?  I am wondering if there's a 
certain code path that is badly optimized?

The slowness you are observing is interesting, since the graphics performance 
of GTK+-OSX on my Mac laptop is faster than the performance of GTK+-X11 on my 
(faster) Linux desktop.

> So another option might be to use gtk-x11 in the Mac build, instead of 
> gtk-osx.  Obviously this would require an X server to be installed but I 
> don't think that's too difficult on a Mac.  The question is whether or not X 
> (under OS-X) also uses QuartzGL or whether it interfaces with Quartz 
> Compositor directly (or via some alternative technology, such as OpenGL).  
> I'm assuming there must be an interface to Quartz Compositor at some stage.

Mac OS X actually ships with an X11 server (X11.app), you can install it from 
the extra components on the Mac OS X installation DVD.

> Anyone know where I could find out some more information about X server for 
> OS-X?

I guess this will be of interest:  http://xquartz.macosforge.org/trac/wiki


regards,

-kris.

___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Hardware accelerated 2D graphics (with gtk-osx)

2010-08-09 Thread John Emmas

On 8 Aug 2010, at 20:58, Kristian Rietveld wrote:

> 
> The slowness you are observing is interesting, since the graphics performance 
> of GTK+-OSX on my Mac laptop is faster than the performance of GTK+-X11 on my 
> (faster) Linux desktop.
> 
> [ ... ]

> 
> What hardware and OS revision are you using?
> 

I'm using a Mac Mini with OS-X 10.6.3.  Graphics are provided by the onboard 
NVidia chip which is a GeForce 9400.  On the Apple Discussions forum they told 
me that this chipset was compatible with the ones that are supposedly supported 
(for hardware acceleration) by QuartzGL.  However, I guess it's entirely 
possible that I might have been informed wrongly.  It's certainly true that any 
attempt to enable hardware acceleration actually makes my 2D performance worse!


> 
> Do you experience this just in your canvas or in other GTK+ applications as 
> well?
> 

This particular app is the only GTK application that I've ever run on my Mac.  
It's an application called Mixbus which is derived from Ardour, the popular 
open-source DAW for linux.  Mixbus is developed by an American company called 
Harrison Inc.  I do know that they use a variety of different Macs for testing 
but they're all displaying the same problem.  Having said that, I might ask if 
they can test it on the PPC platform to see if that makes a difference.  Just 
out ot interest, Kristian - is your Mac laptop a MacBook or a PowerBook? And 
what graphics chipset is it using?

John
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Hardware accelerated 2D graphics (with gtk-osx)

2010-08-09 Thread Kristian Rietveld
On Aug 9, 2010, at 1:39 PM, John Emmas wrote:
> I'm using a Mac Mini with OS-X 10.6.3.  Graphics are provided by the onboard 
> NVidia chip which is a GeForce 9400.

That's certainly pretty recent.

> This particular app is the only GTK application that I've ever run on my Mac. 
>  It's an application called Mixbus which is derived from Ardour, the popular 
> open-source DAW for linux.  Mixbus is developed by an American company called 
> Harrison Inc.  I do know that they use a variety of different Macs for 
> testing but they're all displaying the same problem.


> Having said that, I might ask if they can test it on the PPC platform to see 
> if that makes a difference.  Just out ot interest, Kristian - is your Mac 
> laptop a MacBook or a PowerBook? And what graphics chipset is it using?

I have a MacBook Pro here and I use the GeForce 9400M (it also has a 9600M GT 
which I don't use).  That's pretty much the same as yours, so you would say the 
hardware/driver cannot be the issue.  I also occasionally test stuff on an 
older MacBook with Intel graphics running Tiger, with good performance.

It would be interesting to know whether I can reproduce the problem on my 
machine here.  If so, then I can also look into debugging it.  Is the 
application available somewhere?  Or is there a stand-alone test case that 
shows the same behavior (that would be even better)?


regards,

-kris.
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Hardware accelerated 2D graphics (with gtk-osx)

2010-08-09 Thread John Emmas

On 9 Aug 2010, at 20:06, Kristian Rietveld wrote:

> 
> It would be interesting to know whether I can reproduce the problem on my 
> machine here.  If so, then I can also look into debugging it.  Is the 
> application available somewhere?
> 

Thanks for the offer.  I'd need to ask Harrison if they'd mind me letting you 
have a copy of the app but I'm pretty sure they'd be okay about it.  The 
difficulty though would be in getting you some suitable test material.  Somehow 
I'd need to send you a large Ardour session to experiment with but we're 
talking about a very large amount of data for you to download (and more 
importantly, for me to upload somewhere).  Leave me to think about this.

John
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


running win32 gtk+ program on one computer and displaying graphics on another ?

2009-11-13 Thread Jason H
Greetings,

With the X Window System, I can use "xhost" and set the "DISPLAY"
environment variable to run a program on computer A and have all
the graphics show up on computer B. Is it possible to do something
similar with the Windows version of GTK+? That is, is it possible
to write a program with the Windows version of GTK+, run the program
on one computer, and display the graphics on another computer?

Best wishes,

Jason
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: running win32 gtk+ program on one computer and displaying graphics on another ?

2009-11-13 Thread Tor Lillqvist
> Is it possible to do something similar with the Windows version of GTK+?

Yes and no. Note that there is nothing GTK+-specific in this.

Read up on Remote Desktop Services, earlier known as Terminal Services
(or Terminal Server). See
http://en.wikipedia.org/wiki/Remote_Desktop_Services

It is normally used to connect to a whole remote desktop environment,
but it is possible to start a specific program when connecting, too.
There will still be a normal desktop environment, too, in the Remote
Desktop client window, i.e. it is not like X11. And note that when
connecting to non-server Windows machines, the local console will be
locked out while there is a remote session connected, and that there
can be just one remote session at a time. On server Windowses there
can be more simultaneous sessions, lots more if one purchases the
required licenses. (Surprised...?)

To enable Remote Desktop connections to a machine, one needs to enable
that in the Control Panel, don't recall now exactly where. Also, users
must be a member of the Remote Desktop Users group to be allowed to
log in remotely.

In more "enterprisey" contexts it is possible to start individual
remote applications having them appear as "local" windows, as if
running locally, instead of being inside the Remote Desktop Connection
client. Look for "RemoteApp" on the wikipedia page mentioned above.

There are also non-Microsoft products in this space, especially from Citrix.

--tml
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: running win32 gtk+ program on one computer and displaying graphics on another ?

2009-11-13 Thread Jason H
On Fri, Nov 13, 2009 at 5:50 PM, Tor Lillqvist  wrote:

> > Is it possible to do something similar with the Windows version of GTK+?
>
> Yes and no. Note that there is nothing GTK+-specific in this.
>
> Read up on Remote Desktop Services, earlier known as Terminal Services
> (or Terminal Server). See
> http://en.wikipedia.org/wiki/Remote_Desktop_Services
>
> It is normally used to connect to a whole remote desktop environment,
>
   ... snipped ...
Hi Tor,
Thanks a lot for the info.  I'll read up that page right away.
Best wishes,
Jason
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Cairo, Gtk+, Gdk & GdkPixbuf -- making a pixel-based backing store for vector graphics

2011-06-14 Thread James Tappin
I would like to be able to make a code that draws some (possibly very
complex) vector graphics, copies it to an off-screen backing store and
then when an expose-event (Gtk2) or draw signal (Gtk3) is received,
the backing store is copied to the screen rather than doing a complete
redraw of all the vectors which could potentially take several
seconds. Unfortunately all the potential model codes I've been able to
find use the obsolete Gdk Pixmap as backing store.

Likewise the routine that looks promising
gdk_pixbuf_render_to_drawable () is marked as deprecated (since 2.4)
and suggests gdk_draw_pixbuf () as an alternative. However that is
also marked deprecated (since 2.22) and recommends
gdk_cairo_set_source_pixbuf() and cairo_paint() or cairo_rectangle()
and cairo_fill() but it is not at all clear how to combine those
routines to produce the required effect.

I have searched many times for suitable examples and come up empty. So
does anybody here have any suggestions, examples or link that provide
pointers to the following operations?:

1) Getting cairo to draw to a pixmap or pixbuf, or draw to a window
and then copy the resulting window contents to an in-memory storage.

2) Making the expose handler copy that pixbuf (or whatever) to the
visible window (while only copying the affected region  would be the
best option I can live with copying the whole window).

3) (Less important for now) Adding new material to the plot and
updating the backing store -- my guess is that once I crack 1 & 2 then
3 will be fairly obvious.

James
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Cairo, Gtk+, Gdk & GdkPixbuf -- making a pixel-based backing store for vector graphics

2011-06-14 Thread Stefan Salewski
On Tue, 2011-06-14 at 14:30 -0600, James Tappin wrote:
> I would like to be able to make a code that draws some (possibly very
> complex) vector graphics, 

A better place for asking may be the cairo mailing list? At least there
was some discussion about such tasks in the past. One recommended way
was using cairos create_similar() function for creating the backup
surface. I did a small demo in Ruby some time ago, see

http://www.ssalewski.de/PetEd-Demo.html.en

I found this related thread with some helpful replies:

http://lists.freedesktop.org/archives/cairo/2009-March/016756.html

But I am still interested in smarter solutions.


___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Cairo, Gtk+, Gdk & GdkPixbuf -- making a pixel-based backing store for vector graphics

2011-06-14 Thread James Tappin
On 14 June 2011 15:00, Stefan Salewski  wrote:
> On Tue, 2011-06-14 at 14:30 -0600, James Tappin wrote:
>> I would like to be able to make a code that draws some (possibly very
>> complex) vector graphics,
>
> A better place for asking may be the cairo mailing list? At least there
> was some discussion about such tasks in the past. One recommended way
> was using cairos create_similar() function for creating the backup
> surface. I did a small demo in Ruby some time ago, see
>
> http://www.ssalewski.de/PetEd-Demo.html.en
>
> I found this related thread with some helpful replies:
>
> http://lists.freedesktop.org/archives/cairo/2009-March/016756.html
>


It looks as if this example:
http://www.gtkforums.com/viewtopic.php?t=5204, may at least provide
part of the answer to (1) in my original posting -- I'm still trying
to disentangle the housekeeping and the real logic, to figure exactly
what it does.
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Cairo, Gtk+, Gdk & GdkPixbuf -- making a pixel-based backing store for vector graphics

2011-06-14 Thread Emmanuel Thomas-Maurin
On 06/14/2011 10:30 PM, James Tappin wrote:
> I would like to be able to make a code that draws some (possibly very
> complex) vector graphics, copies it to an off-screen backing store and
> then when an expose-event (Gtk2) or draw signal (Gtk3) is received,
> the backing store is copied to the screen rather than doing a complete
> redraw of all the vectors which could potentially take several
> seconds. Unfortunately all the potential model codes I've been able to
> find use the obsolete Gdk Pixmap as backing store.

You may draw to a cairo image surface (instead of a GDK pixmap) then
draw that image to a cairo surface (instead of a GTK drawing area.)

surface = cairo_image_surface_create();
(vector graphics drawing)

cr = gdk_cairo_create(GDK_DRAWABLE(drawing_area->window));
cairo_set_source_surface(cr, surface, dest_x - src_x, dest_y - src_y);
cairo_rectangle(cr, dest_x, dest_y, drawing_area_width,
drawing_area_height);
cairo_set_operator(cr, CAIRO_OPERATOR_SOURCE);
cairo_fill(cr);
cairo_destroy(cr);

-- 
Emmanuel Thomas-Maurin 
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Cairo, Gtk+, Gdk & GdkPixbuf -- making a pixel-based backing store for vector graphics

2011-06-17 Thread James Tappin
Just to let folks know that the pointers here have given me the lead
in that I needed and I've got a working code. (A bit more elegant in
the Gtk3 case than Gtk2 but both work).
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list