Hi,
I am looking for the best way to determine if a text based or mixed text/image PDF page contains only black & white text or contains color. I don't see a function in GDPicturePDF to return that info.
Am I correct that I should render the page to an image and then use the ColorDetection method on the resulting image?
If so, should I render 1st at a very low dpi, and then re-render at the higher dpi once I know what PixelFormat I want the page rendered?
Or should I render 1st at the normal (say 200) dpi, perform the detection, then convert to a more compact format once the Intent (color/black & white) is known?
Ultimate goal is to get each page of the PDF into a TIF raster, appropriately either at 1bpp CCITTG4 or 24bpp JPEG in TIF.
Thanks!
Determine Color usage in PDF
Re: Determine Color usage in PDF
Hello,
It is very easy and you do not need to do multiple rasterizations at different resolution or anything, here is a complete working example demonstrating the exact same goal you're trying to achieve:
https://www.gdpicture.com/guides/gdpicture/web ... anism.html
Cheers!
It is very easy and you do not need to do multiple rasterizations at different resolution or anything, here is a complete working example demonstrating the exact same goal you're trying to achieve:
https://www.gdpicture.com/guides/gdpicture/web ... anism.html
Cheers!
Who is online
Users browsing this forum: No registered users and 0 guests