How to Set DPI for Slides when Rendering Them to Graphics2D in Java?

@mirnalini,

Could you kindly provide a test project with an example of the memory problem?

It all depends on what you need. Could please describe the use case in more detail? We will do our best to help you.

We want to get the slide image to a graphics object. We tried using renderToGraphics but that was not fitting to the graphics size.
Current we got the thumbnail of the slide with the width and height of the graphics object and used drawImage which perfectly works for us. But the problem is when drawing such huge images we are seeing out of memory exception.
If there is a method which can help us draw the image of the slide object to a graphics object, it would be great for us.

@mirnalini,
Thank you for the details.

Could you kindly share a sample project that reproduces the problem?