Re: Comic Book retro style dots [Re: [Gimp-user] Camera to Comic Book]

2005-06-01 Thread Asif Lodhi
Hi,

Alan and Sven, thanks for the help.

On Mon, May 30, 2005 at 2:20 AM, Sven Neumann [EMAIL PROTECTED] wrote:
 You are probably still using GIMP 2.0 then.
Yes! 2.0.5.  I did downloaded some dependencies for 2.2.6 and will now
download any dependencies for 2.2.7 that differ from 2.2.6.  As a
learning task, I want to install Gimp from source-tarballs including
all the dependencies under my home directory.

Yes, I should have searched appropriate resources before posting my
query!  I am sorry!

On 6/1/05, Alan Horkan [EMAIL PROTECTED] wrote:
 
 As you probably have arleady been told you should upgrade to Gimp 2.2
 
 - Alan

Yes.  Thank you.

Best regards

Asif
___
Gimp-user mailing list
Gimp-user@lists.xcf.berkeley.edu
http://lists.xcf.berkeley.edu/mailman/listinfo/gimp-user


Re: [Gimp-user] Overlaying and scaling images

2005-06-01 Thread Jeffrey Brent McBeth
On Wed, Jun 01, 2005 at 11:38:23PM +0100, Dylan wrote:
 Hi All,
 
 I'm trying to overlay images of maps onto aerial protographs. Using the 
 photo as a background, I need to scale and rotate the map image so that 
 the two line up. Is this possible with the Gimp? What approach should I 
 use?
 
 If it's not feasable with Gimp, does anyone know any (Linux) software 
 which would be suitable?

Definitely possible and feasable.  As long as you have a simple perspective
transform in your images.  Once things like WGS'84 and other coordinate
systems rear their head, the best bet is something made for this like GRASS.

Anyway, the main tool you would be looking for is the Rotate, Scale, Shear,
and Perspective tools (Shift-R, Shift-T, Shift-S, Shift-P by default)
Perspective and Rotate will probably be the most useful.

I've done it, and it works as long as your data isn't too distorted.  Don't
try anything like the overlays Google Maps does, though, you would
definitely need something like GRASS then.

Jeff

-- 

Computer Science is as much about computers as astronomy is about telescopes
-- Edsger Wybe Dijkstra (1930-2002)



pgpxLe5crwnwQ.pgp
Description: PGP signature


[Gimp-user] Anyone good at converting/porting scripts from perl to python?

2005-06-01 Thread Rikard Johnels
I have been trying to get Gimp Perl to run without success for a while now.
I have decided to try another way..
The script i want to run is as follows;

#!/usr/bin/perl

use Gimp qw( :auto );
use Gimp::Fu;

registercenter_guide,
Creates h-  v-guides at the center of the image.,
Physical center = width/2 and height/2; Optical center = the 
Golden Mean.,
Claes G Lindblad [EMAIL PROTECTED],
Claes G Lindblad,
990323,
Image/Center Guide,
*,
[
[PF_RADIO,
center,
center,
 0,
[Physical = 0, Optical = 1]
]
],
sub {
my ($img, $layer, $center) = @_;

$w = $img-width();
$h = $img-height();
$hc = int($h/2 + 0.5);
$vc = int($w/2 + 0.5);

if ($center == 1) {
$hc = int(($h / 2.6179) + 0.5);
};
$bit_bucket = $img-add_hguide($hc);
$bit_bucket = $img-add_vguide($vc);
gimp_drawable_update($layer, 0, 0, $w, $h);
};
exit main;



How do i convert it to python?
Python i DO have working...

(I did try to mail the author, but i got a bounced mail...)


-- 

 /Rikard

 Sharing knowledge is the most fundamental act of friendship. 
Because it is a way you can give something without loosing something. 
-R. Stallman 

---
Rikard Johnels  email   : [EMAIL PROTECTED]
Mob : +46 763 19 76 25
PGP : 0x461CEE56
---
___
Gimp-user mailing list
Gimp-user@lists.xcf.berkeley.edu
http://lists.xcf.berkeley.edu/mailman/listinfo/gimp-user


Re: [Gimp-user] Anyone good at converting/porting scripts from perl to python?

2005-06-01 Thread Carol Spears
On Thu, Jun 02, 2005 at 03:39:30AM +0200, Rikard Johnels wrote:
 I have been trying to get Gimp Perl to run without success for a while now.
 I have decided to try another way..
 The script i want to run is as follows;
 
just rewrite it.

pyslice has code that uses guides.  you can search the gimps python
guide calls via the python console.

just rewrite it.

i have found scripting with python and gimp to be fun and rewarding and
a source of instant gratification.

ask specific questions here if you run into trouble.

i cannot imagine rewriting perl into python since i can read python and
cannot read perl.  how do you make something that is obfiscuated into
something that is not?  i say skip it and rewrite it, simply.

carol

___
Gimp-user mailing list
Gimp-user@lists.xcf.berkeley.edu
http://lists.xcf.berkeley.edu/mailman/listinfo/gimp-user


Re: [Gimp-user] Anyone good at converting/porting scripts from perl to python?

2005-06-01 Thread Joao S. O. Bueno Calligaris
On Wednesday 01 June 2005 22:39, Rikard Johnels wrote:
 I have been trying to get Gimp Perl to run without success for a
 while now. I have decided to try another way..
 The script i want to run is as follows;


I do not know much perl, but it is quite straightforward.
I suppose you know that in python identation does matter, and is used 
to separate blocks, instead of {}  or begin  end.

That said, the script bellow becomes:

(I will let the perl lines commented on the script. you may erase then 
later)

#!/usr/bin/python

#use Gimp qw( :auto );
#use Gimp::Fu;
# I don't know what this auto: means,
#but we normally just import gimpfu in python scripts/

from gimpfu import *

#registercenter_guide,
# the register call in python must come after the function definition 
#itself. Ok - this is  thasy perl way, in which the function was
#defined inside the funcion call for register. Python is  a clean
#language - the only way of doing this is with short functions
#that can be written as lambdas.

#sub {
#my ($img, $layer, $center) = @_;
def center_guide (img, layer, center):
 #beware of indentation from this point on

 #$w = $img-width();
 #$h = $img-height();
 #$hc = int($h/2 + 0.5);
 #$vc = int($w/2 + 0.5);

 w = img.width
 h = img.height
 hc = int (h / 2.0 + 0.5)
 vc = int (w / 2.0 + 0.5)

 #if ($center == 1) {
 #  $hc = int(($h / 2.6179) + 0.5);
 #};
 if center == 1:
  hc = int (h / 2.6179 + 0.5)

 #  $bit_bucket = $img-add_hguide($hc);
 #  $bit_bucket = $img-add_vguide($vc);
 #  gimp_drawable_update($layer, 0, 0, $w, $h);
 img.add_hguide (hc)
 img.add_vguide (vc)
 gimp.displays_flush()  

 #   };

register   (center_guide,
Creates h-  v-guides at the center of the image.,
Physical center = width/2 and height/2; Optical center = 
the Golden Mean.,
 Claes G Lindblad [EMAIL PROTECTED],
 Claes G Lindblad, pythonified by Joao S. O. Bueno 
Calligaris,
  990323,
  Image/Center Guides,
  *,
  [
[PF_RADIO,
center,
center,
 0,
 ((Physical, 0), (Optical, 1))
]
  
  ],
  [],
  center_guide
  )  


#exit main;
main ()






 How do i convert it to python?
 Python i DO have working...

 (I did try to mail the author, but i got a bounced mail...)
___
Gimp-user mailing list
Gimp-user@lists.xcf.berkeley.edu
http://lists.xcf.berkeley.edu/mailman/listinfo/gimp-user