473,385 Members | 1,766 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

PIL JPEG mis-step

I got the Python Imaging Library from source, built and installed, on
Ubuntu 7.10, not realizing I could run a self-test first. libjpeg is
on the machine, but was not detected.. so no JPG encoder. I got the
dev-libjpg and rebuilt PIL. The self-test now shows JPG support.

but running setup.py install again seems to succeed, but still no
JPG :-(

fix ideas appreciated
Jun 27 '08 #1
3 2599
On Sat, 03 May 2008 15:25:35 -0700, darkblueB wrote:
I got the Python Imaging Library from source, built and installed, on
Ubuntu 7.10, not realizing I could run a self-test first. libjpeg is on
the machine, but was not detected.. so no JPG encoder. I got the
dev-libjpg and rebuilt PIL. The self-test now shows JPG support.

but running setup.py install again seems to succeed, but still no JPG
:-(

fix ideas appreciated
Make sure that libjpeg62-dev is installed
'sudo apt-get install libjpeg62-dev'

Try run 'python setup.py build_ext -f' to force setup.py to rebuild
everything with JPEG. And 'sudo python setup.py install' should install
PIL with JPEG support.

It should work on Ununtu 7.10 (works for me at least).

However, if you want Tkinter support, you should edit setup.py and change
TCL_ROOT variable:
TCL_ROOT = '/usr/lib/tcl8.4', '/usr/include/tcl8.4'

And make sure that you have tcl/tk libraries/headers:
sudo apt-get install tcl8.4-dev tk8.4-dev
--
Ivan
Jun 27 '08 #2
On May 3, 4:52*pm, Ivan Illarionov <ivan.illario...@gmail.comwrote:
Try run 'python setup.py build_ext -f' to force setup.py to rebuild
everything with JPEG. And 'sudo python setup.py install' should install
PIL with JPEG support.
yes, that works

(the self test still gives misleading results ?)
but running some sample program works fine

thanks
Jun 27 '08 #3
On Sat, 03 May 2008 17:01:44 -0700, darkblueB wrote:
On May 3, 4:52Â*pm, Ivan Illarionov <ivan.illario...@gmail.comwrote:
>Try run 'python setup.py build_ext -f' to force setup.py to rebuild
everything with JPEG. And 'sudo python setup.py install' should install
PIL with JPEG support.

yes, that works

(the self test still gives misleading results ?) but running some sample
program works fine

thanks
You're welcome. To make self test inside source directory work you
probably should rebuild it inplace too.
python setup.py build_ext -f -i
Jun 27 '08 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Ming | last post by:
Hi All, I want to write a PHP webpage which allows people to upload images (no matter what formats) to me and at the same time converts any non-jpeg image to JPEG. Here's what I have: ...
3
by: Steve Holden | last post by:
If nobody has a quick answer I'll go to the PIL list, but I'm having problems with PIL JPEG support on Windows, and figured someone on c.l.py might have solved this problem. I built the Cygwin...
0
by: frankenberry | last post by:
I have multi-page tiff files. I need to extract individual frames from the multi-page tiffs and save them as single-page tiffs. 95% of the time I receive multi-page tiffs containing 1 or more black...
3
by: bull.enteract | last post by:
Ok, I start off with a bitmap image. I encode it as a jpeg and send it across the network and pick it up on the other end. Now I have the jpeg image on the other end as an arrray of bytes and I...
16
by: David Lauberts | last post by:
Hi Wonder if someone has some words of wisdom. I have a access 2002 form that contains 2 graph objects that overlay each other and would like to export them as a JPEG to use in a presentation....
0
by: Johann Blake | last post by:
In my need to decode a JPEG 2000 file, I discovered like many that there was no functionality for this in the .NET Framework. Instead of forking out a pile of cash to do this, I came up with the...
10
by: rtilley | last post by:
Hope it's not inappropriate to post this here. Could someone critique my code? I have no Python programmers in my office to show this to. The script works OK, but should I do it differently? I...
0
by: Jack Wu | last post by:
Hi I've spent a good majority of my day trying to figure out how to have PIL 1.1.5 working on my OSX 10.3.9_PPC machine. I'm still stuck and I have not gotten anywhere. Could somebody please...
1
by: Smokey Grindel | last post by:
I have a bitmap object I want to return as a JPEG image with a compression set at 90% and progressive passes enabled, how can I do this in .NET 2.0? Progressive passes are not necessary but the...
1
by: Joe Cool | last post by:
I am attempting to add a function to an application I am working on to modify the JPEG Comment in a Jpeg image file. I can retrieve the JPEG Comment with no problem. The problem is modifying it....
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.