VoyForums
[ Show ]
Support VoyForums
[ Shrink ]
VoyForums Announcement: Programming and providing support for this service has been a labor of love since 1997. We are one of the few services online who values our users' privacy, and have never sold your information. We have even fought hard to defend your privacy in legal cases; however, we've done it with almost no financial support -- paying out of pocket to continue providing the service. Due to the issues imposed on us by advertisers, we also stopped hosting most ads on the forums many years ago. We hope you appreciate our efforts.

Show your support by donating any amount. (Note: We are still technically a for-profit company, so your contribution is not tax-deductible.) PayPal Acct: Feedback:

Donate to VoyForums (PayPal):

Login ] [ Contact Forum Admin ] [ Main index ] [ Post a new message ] [ Search | Check update time | Archives: 12345678[9]10 ]


[ Next Thread | Previous Thread | Next Message | Previous Message ]

Date Posted: 07:01:38 07/27/00 Thu
Author: Michel
Subject: Re: Envision Library Oddities (but new user as well!)
In reply to: Chris Swinney 's message, "Re: Envision Library Oddities (but new user as well!)" on 12:17:12 07/26/00 Wed


Hi Chris,

To test for a gray scale image you only need to look at the palette. All the palette entries must have the R,G,B values identical, because if for a single entry they are not one color channel would be more domimant than the others, so it would not be gray. The Palette property in the TDibGraphic class allows you to examine the palette entries without having to look at every pixel in the image.

For the TIFF related problem, I have done the steps you indicated, and indeed the error "compression tag 6 not supported error" is raised. I do find this strange, because compression JPEG "6" is obsolete in the latest tiff spec, and I wonder why Windows Imaging is using it. This is not supported by Envision. The more common JPEG compression tag has the value "7". You can get more information on this at this link <a rel=nofollow target=_blank href="ftp://ftp.sgi.com/graphics/tiff/TTN2.draft.txt.gz">ftp://ftp.sgi.com/graphics/tiff/TTN2.draft.txt.gz</a>


Best regards,

Michel

> Thanks for the response, Sorry now for my delay, I
> thought I post once a few days ago bu tit assn't
> appeared. Comments below.
>
> > Dear Chris,
> >
> > I apologies for the delay. I have been on vacation
> and
> > was planning to continue working on Envision, but I
> took > the time off instead.
> >
> everyone needs a break!
>
>
> > Most scanners will return ifColor256
> >
> > with gray scale images. A gray scale image is really
> a
> > color image, where the palette
> >
> > entries have the same R, G, and B values. The only
> way
> > to know for sure is to look at the
> >
> > palette.
> >
> The 256 colour/grey pallet pixel as I understand it is
> made up of an 8 bit number split into RGB (3/3/2). I'm
> not sure of the relationships between the bits to
> determine whether the pallet is grey or not. Anyway, I
> assume you would need to test every pixel useing
> scanline or some such, Would this take to long or
> would it just be simpler to make a note the what
> pallet the user asked for and covert it just after the
> scan and just before the stream write?
>
> > For reading the TIFF file with JPEG compression, I'm
> > not sure what the error you are
> >
> > receiving is. The first possibility is that the
> > exception is raised internally and handle by
> >
> > the library itself. Does the TIFF file load properly
> > with the compiled Demo.EXE program?
> >
> > Best regards,
> >
> > Michel
> >
> >
> No, the demo desn't work either. Take a tiff image in
> Windows Imaging or such, and change the properties of
> a page to 256 gray or ture colour, then use JPEG
> compression and save it. Now try to open the document
> in the demo and you should recieve the "compression
> tag 6 not supported error". This si an internal error
> but I am away from the development machine at the mo
> so cant say exactly where.
>
> Thanks for any further insight.
>
> Chris

[ Next Thread | Previous Thread | Next Message | Previous Message ]


Replies:


[ Contact Forum Admin ]


Forum timezone: GMT-5
VF Version: 3.00b, ConfDB:
Before posting please read our privacy policy.
VoyForums(tm) is a Free Service from Voyager Info-Systems.
Copyright © 1998-2019 Voyager Info-Systems. All Rights Reserved.