[Gambas-user] Difference between Picture and Image?

Rob sourceforge-raindog2 at ...94...
Thu Jan 13 14:10:14 CET 2005


On Thursday 13 January 2005 06:18, Eilert wrote:
> What is the difference between Image and Picture?

To explain this difference, I first have to explain to you how 
X11 (the graphics subsystem of Linux and almost every other 
Unix) works a little bit.  With X, your program can run on one 
machine but have its window display on a machine somewhere else 
on the Internet, if you want it to.  This is so that you can 
have one big fast server running many copies of one application, 
and a bunch of cheap little terminals displaying that 
application (basically, "thin clients", but they didn't use that 
term at the time.)

An Image is a graphic that lives in your program.  As such, you 
have more access to it and can do more stuff to it, like 
stretch, fine rotate, etc.

A Picture is a graphic that lives on your X display, whether it's 
on the same machine or in Mongolia or whatever.  So any 
manipulation you do to this picture will happen over a network 
link or a local pipe, and as such it's likely to be a lot 
slower.

In graphic-intensive apps, I have found myself converting between 
Image and Picture quite a bit to use different features of each.  
I wonder if Gtk has these issues with process-space graphics vs. 
display-space ones, because it's confusing and a little 
annoying, even though I understand why it has to be.  Maybe an 
ImageMagick component would help this somewhat.  Hey Srikanta, 
maybe that could be a cool first project for you :)

To sum up, here's how you can think of them: Image is for 
manipulation, Picture is for display.

Rob








More information about the User mailing list