ALT Linux Community general discussions
 help / color / mirror / Atom feed
From: spider <spider@lsi.bas-net.by>
To: lhome@academ.org, ALT Linux Community <community@lists.altlinux.org>
Subject: Re: [Comm] ps (pdf) to djvu
Date: Thu, 06 Apr 2006 17:41:28 +0300
Message-ID: <44352898.9070204@lsi.bas-net.by> (raw)
In-Reply-To: <e0rcs4$uf9$1@sea.gmane.org>

Andrei Lomov wrote:
> Кто-нибудь делал преобразование
> ps (pdf) to djvu ?
> 
Для тех, что есть обертка сканированных документов делаю так:

1. Перегоняю пдф в картинки -- их будет столько, сколько страниц в
документе.

$ pdftoppm -r 300 -mono file.pdf m300

В результате имеем кучу файлов m300-000001.ppm ... m300-000nnn.ppm

2. теперь перегоняем эти картинки в djvu

$ find -name '*.pbm' -exec cjb2 -lossy {} {}.d \;

3. И собираем воедино

Первая страница из первой картинки.
$ djvm -c book.djvu m300-000001.pbm.d

Для правильной сборки остальных делаем скрипт
$ find -name '*.d' -exec echo djvm -i book.djvu {} \; | sort > a.sh

устанавливаем ему флаг выполняемости и запускаем. Все ненужное прибиваем.


      parent reply	other threads:[~2006-04-06 14:41 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-04-03 14:52 Andrei Lomov
2006-04-03 15:01 ` [Comm] [JT] " Alexei V. Mezin
2006-04-03 15:53   ` Alexej Kryukov
2006-04-03 17:29   ` some_x
2006-04-03 18:03   ` Gleb Kulikov
2006-04-06 14:55   ` spider
2006-04-09 13:19     ` Andrei Lomov
2006-04-09 13:49       ` some_x
2006-04-03 17:57 ` [Comm] " Gleb Kulikov
2006-04-06 14:41 ` spider [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=44352898.9070204@lsi.bas-net.by \
    --to=spider@lsi.bas-net.by \
    --cc=community@lists.altlinux.org \
    --cc=lhome@academ.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

ALT Linux Community general discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/community/0 community/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 community community/ http://lore.altlinux.org/community \
		mandrake-russian@linuxteam.iplabs.ru community@lists.altlinux.org community@lists.altlinux.ru community@lists.altlinux.com
	public-inbox-index community

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.community


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git