Redacting all images #914
-
First of all. This tool is incredible and the support is unreal. Jorj, I am learning a lot just from reading the exchanges here. Thanks I would like to redact every image in a PDF. My attempt is:
While this does not get me the desired effect, the output file has a red cross over every image I would like to redact. So the tool is smarter than I am. I know this is due to the page.apply_redactions() not being nested correctly, but can I leverage this to redact the images somehow? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
First of all: thanks a lot for the compliments - very rewarding indeed! When you say "Redact the images", then you mean delete them and put a textbox there instead, right?
|
Beta Was this translation helpful? Give feedback.
First of all: thanks a lot for the compliments - very rewarding indeed!
When you say "Redact the images", then you mean delete them and put a textbox there instead, right?
page.apply_redactions()
is not indented correctly. As it is placed, it will only redact the last page of the document. Maybe that one didn't even have an image?page.get_page_images()
really is an existing image on the page. Need not be the case because of how your PDF may be designed. The returned bbox will be "infinite" then.