Re: Extracting alphachannel from .pics
| Date : Tue, 02 Oct 2007 18:21:48 +0200 |
| To : XSI(at)Softimage.COM |
| From : Philipp Oeser <philipp.oeser(at)liga01.de> |
| Subject : Re: Extracting alphachannel from .pics |
And at first it flipped the images upside down...
But when you change line 97 from
-------------------------------------------------------------------------
tmp = Image.frombuffer('L', self.size, buff[i::len(mode)]).im
-------------------------------------------------------------------------
to
-------------------------------------------------------------------------
tmp = Image.frombuffer('L', self.size, buff[i::len(mode)], "raw", 'L', 0, 1).im
-------------------------------------------------------------------------
it works allright
Thanx again Philipp
Philipp Oeser schrieb:
Hi everyone and thanx for your suggestions,
the extract-utility does what I need, great! As for imagemagick, I think they dont handle .pics either, right?
But the most interesting is indeed the PIL-Plugin
I got it to work when calling it directly (so it does its job),but when I place the file in Python\Lib\site-packages\PIL and then want to open a pic with Image.open() I still get an error "IOError: cannot identify image file". Did you get it to work as a regular plugin, Dana?
The script seems to register OK, but like I said, I still get the error. If anyone knows how to do this right, I'd be more than thankful
==============================
Image.register_open("PICT", SoftimageImageFile)
Image.register_extension("PICT", ".pic")
==============================
Regards Philipp
Dana Smith schrieb:Also found this:
http://svn.red-bean.com/bob/SoftimageImage/trunk/SoftimageImage.py
Dana L. Smith Technical Infrastructure Management SAS (919) 531-4116 Dana.Smith(at)sas.com http://www.sas.com
-----Original Message-----
From: owner-xsi(at)Softimage.COM [mailto:owner-xsi(at)Softimage.COM] On Behalf Of Dana Smith
Sent: Friday, September 28, 2007 1:48 PM
To: XSI(at)Softimage.COM
Subject: RE: Extracting alphachannel from .pics
You might be able to do this with ImageMagick for Python (PythonMagick).
Dana L. Smith Technical Infrastructure Management SAS (919) 531-4116 Dana.Smith(at)sas.com http://www.sas.com
-----Original Message-----
From: owner-xsi(at)Softimage.COM [mailto:owner-xsi(at)Softimage.COM] On Behalf Of Philipp Oeser
Sent: Tuesday, September 25, 2007 8:04 AM
To: XSI(at)Softimage.COM
Subject: Re: Extracting alphachannel from .pics
Hi Vladimir,
its an external python-tool...
(while writing this I'm thinking...maybe someone has a module to load .pics with PIL - its one of the rare formats it doesnt read by default -? Anyone handles .pics with python?)
Philipp
Vladimir Jankijevic schrieb:
do you need to script it? if so, you could do it with the fxtree. just a suggestion... vladi
Philipp Oeser wrote:
Hi,
i need to write an alphachannel from a .pic to a seperate file (as a thumbnailed jpg). Anyone knows how to do this with 'imf_copy' or 'imgconv'?
[Other than that I could convert to rgba .tga and use pythons PIL to pull the alpha, but would be faster to do in one step...]
Any hints welcome... Philipp
--
LIGA_01 COMPUTERFILM GmbH Philipp Oeser
MUNICH Landwehrstrasse 60-62 80336 Munich, Germany fon: +49 - (0)89 - 51 555 8-88 fax: +49 - (0)89 - 51 555 8-77
www.liga01.com
Diese Nachricht enthält vertrauliche und/oder rechtlich geschützte Informationen. Wenn Sie nicht der richtige Adressat sind oder diese Nachricht irrtümlich erhalten haben, informieren Sie bitte den Absender und löschen diese Nachricht. Das unerlaubte Kopieren und die unbefugte Weiterleitung dieser Nachricht sind nicht gestattet.
This message may contain confidential and/or privileged information. If you are not the intended recipient or if you have received this message in error, please notify the sender and delete this message. Any unauthorised copying, disclosure or distribution of this message is strictly forbidden.
--- Unsubscribe? Mail Majordomo(at)Softimage.COM with the following text in body: unsubscribe xsi
- References:
- Re: Extracting alphachannel from .pics
- From: Philipp Oeser <philipp.oeser(at)liga01.de>
- Re: Extracting alphachannel from .pics
| DATE: | << | >> | THREAD: | << | >> | INDEX: | Main | Thread |
|---|
- Previous by Date: Re: Hide Component Operator
- Next by Date: Re: Hide Component Operator
- Previous by Thread: Re: Hide Component Operator
- Next by Thread: Re: Hide Component Operator
- Index(es):
| Search the XSI List archives here or use the advanced search form to search across mailing lists. Searching help is available. |