LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 11-25-2004, 10:13 AM   #1
satimis
Senior Member
 
Registered: Apr 2003
Posts: 3,695

Rep: Reputation: 56
ImageMagick question


Hi folks,

FedoraCore2
===========

ImageMagick is completely new to me.

I'm searching for a software working as a desk/platform allowing scaned pictures/documents to be manupulated on it such as;

1) combining scaned pictures/documents as a book
2) typing notes/lines on pictures/documents
3) simple graphic editing
4) pages in the book can be resort, such as taking out page-2 putting it as page-10, etc.
5) save/export/print the book in pdf, png, ps, etc. format

Is ImageMagick the right tool for me? Any folk having experience on this tool please shed me some light.

I can evoke ImageMagick by running following command on console;
$ display logo:Untitled

But I could not locate scanner plugin there similar to 'Kooka'

TIA

B.R.
satimis
 
Old 11-25-2004, 10:37 AM   #2
rjlee
Senior Member
 
Registered: Jul 2004
Distribution: Ubuntu 7.04
Posts: 1,994

Rep: Reputation: 76
ImageMagick is great for converting images, and for batch processing of lots of images at once using scripts.

If you're interested in processing individual images, then the GNU Image Manipulator Program (GIMP) is an very strong graphical tool (try a freshmeat.net search), and it also allows you to acquire images from a scanner through SANE.

SANE is the technology used by Linux to acquire images from digital devices (scanners and some stills cameras); search for information on SANE if you want a command-line tool to handle this.
 
Old 11-25-2004, 07:35 PM   #3
satimis
Senior Member
 
Registered: Apr 2003
Posts: 3,695

Original Poster
Rep: Reputation: 56
Hi rjlee,

Tks for your advice.

Quote:
If you're interested in processing individual images, then the GNU Image Manipulator Program (GIMP) is an very strong graphical tool (try a freshmeat.net search), and it also allows you to acquire images from a scanner through SANE.
I'm using GIMP to do this job with SANE scanning images/document. But GIMP is a heavy tool for this simple job. I also use 'convert' function of ImageMagick binding scanned images as book.

I'm searching for some simple tools on Linux World to do this job. On Windows there are many of them but I can't find their equivalent on Linux. Previously some folks suggested using ebook software. Neither I have tried nor I have knowledge on ebook software.

Futhermore do you know any pdf/ps tools spiced up with ImageMagick. TIA

B.R.
satimis

Last edited by satimis; 11-25-2004 at 07:40 PM.
 
Old 11-27-2004, 07:23 PM   #4
rjlee
Senior Member
 
Registered: Jul 2004
Distribution: Ubuntu 7.04
Posts: 1,994

Rep: Reputation: 76
Scribus is a good general-purpose drawing/layout utility.

Conversion to postscript is generally called “printing to a file” in Linux; most utilities will allow you to “print” out a postscript file (printer spoolers expect documents in postscript format).

ps2pdf and pdf2ps come as a part of ghostscript as standard and convert between postscript and portable document format.

ps2pdf, pdf2ps and all of the imagemagick commands support the use of a - on the command-line to mean “standard input” or “standard output” so it's quite easy to pipe them together:
Code:
ps2pdf saved.ps - | pdf2ps - - | ps2pdf - converted.pdf
(this converts saved.ps to PDF, converts it back into ps, then converts it back into PDF, saving the end result as converted.pdf. Just an example of pipeing; see the bash manpage for more.)

Last edited by rjlee; 11-27-2004 at 07:25 PM.
 
Old 11-27-2004, 08:10 PM   #5
satimis
Senior Member
 
Registered: Apr 2003
Posts: 3,695

Original Poster
Rep: Reputation: 56
Hi rjlee,

Tks for your advice.

Scribus, ps2pdf and pdf2ps, etc. are all new to me. I'll have a look later.

My problem is;

If I have 100+ scanned documents in a directory which
is created for scanning, can I apply following
'convert' command line binding them as book.

$ convert ~/pathto/dir-scan/* book.pdf

instead of in 'dir-scan' directory applying

$ convert doc-001 doc-002 doc-003 (etc.) book.pdf

(doc-001 will become page-1, doc-002 page-2, doc-003
page-3, etc.)

If each document has its name, say aaa, bbb, ccc, etc.
then I have to make their names as doc-001-aaa,
doc-002-bbb, doc-003-ccc, etc.

Now if I want to place doc-003-ccc as page-1 and
doc-001-aaa as page-3 whether just changing;

doc-001-aaa as doc-003-aaa
and
doc-003-ccc as doc-001-ccc

The command 'convert' will detect them to do the job
automatically.

How about I just need to make doc-001-aaa as Page-50
and let the other pages pushed upward then there will
be lot of work. Is there any other way?

TIA

B.R.
satimis
 
Old 11-28-2004, 06:59 AM   #6
rjlee
Senior Member
 
Registered: Jul 2004
Distribution: Ubuntu 7.04
Posts: 1,994

Rep: Reputation: 76
convert will convert the images in the order in which they appear on the command-line.

When you glob multiple files together using * or ? escapes, the shell will extract the files in roughly alphabetical order (capital letters come before small letters, numbers before that and so on). It's the same order that you get with the command
Code:
ls -1 ~/pathto/dir-scan/*
So yes, you can swap the filenames to change the order that they appear in.

Moving page 50 to page 1 isn't too hard; you can just rename it as doc-001-aa (which will come before doc-001-aaa, so the other files will move down). However, this is rather hard if you want to keep the page number in the filename.

Just an idea, but another trick you can do, if you don't have any spaces or obscure punctuation in the filenames, is to make a list of the files in the order you want them to appear in, one file per line. Let's say this list is stored in the file “file.list”. You can then just put this list into the command-line using backticks:
Code:
convert `cat file.list` book.pdf
(cat just types out the contents of the file). This way, there's no reason to keep the page number in the filename (if you want to know which page an image occurs on, you can just search for it in the list file and read off the line number).
 
Old 11-29-2004, 12:03 AM   #7
satimis
Senior Member
 
Registered: Apr 2003
Posts: 3,695

Original Poster
Rep: Reputation: 56
Hi rjlee,

Quote:
Just an idea, but another trick you can do, if you don't have any spaces or obscure punctuation in the filenames, is to make a list of the files in the order you want them to appear in, one file per line. Let's say this list is stored in the file “file.list”. You can then just put this list into the command-line using backticks:
Code:
convert `cat file.list` book.pdf
(cat just types out the contents of the file). This way, there's no reason to keep the page number in the filename (if you want to know which page an image occurs on, you can just search for it in the list file and read off the line number).
Noted with thanks

B.R.
satimis
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
ImageMagick without X jeru Debian 4 08-21-2004 08:29 PM
ImageMagick tips Tinkster Linux - Software 2 03-20-2004 07:19 AM
ImageMagick jasonmcneil0 Linux - Software 2 11-14-2003 07:49 PM
ImageMagick-5.5.6 tailine Linux - Distributions 1 06-12-2003 09:56 AM
ImageMagick! ifm Linux - Software 0 06-20-2002 10:13 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 02:14 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration