I am using below code to extract image from pdf :-
Code: Select all
$imagick = new Imagick();
$imagick->readImage('D:\DBCL\1.pdf');
$imagick->writeImage('D:\DBCL\output.jpg');
But when I try to fetch width and height of saved image its not give me the original height and width which I have given in pdf.
Issue is pdf will be uploaded by end user so I am not able to give resolution in above code.
So please help me to save image from pdf in the original resolution, height and width.
Any help will be appreciated.
Thanks in Advance.