pdfbox-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tilman Hausherr <THaush...@t-online.de>
Subject Re: rubberstamp annotation with base 64 image
Date Thu, 01 Jun 2017 15:28:42 GMT
Am 01.06.2017 um 14:08 schrieb Peter Pinnau:
> Hallo
>> but the sample shows loading it from a file.
>>
>> im looking to create a BufferedImage from a base64 svg string. has 
>> anybody
>> tried this?
> I think you can create a PDImageXObject object from a BufferedImage using
>
> org.apache.pdfbox.pdmodel.graphics.image.JPEGFactory factory
>
> JPEGFactory.createFromImage( PDDocument, BufferedImage , float 
> quality, int resolution);
>
>


I'd advise against converting an image that isn't a photograph to jpeg, 
this will have artefacts. Use LosslessFactory instead.


Tilman


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
For additional commands, e-mail: users-help@pdfbox.apache.org


Mime
View raw message