How to save a pic with certain dpi by root

Hi,Rooters:
Is there any method to save the root file as a pic with certain dpi? like 300 or 600?
I installed an Historoot to do this, but it seems can’t open root files, anyone knows how to solve this problem?

Any Advice will be appreciated. [-o<
Thanks in advance.

Honghu

Hi Honghu,

you can set the size of the canvas at construction time: root.cern.ch/doc/master/classTC … 780e93f151

Cheers,
Danilo

Hi,Danilo
Thanks for your reply.
The size of pixel can be set in the construction of canvas:
TCanvas::TCanvas ( const char * name,
const char * title,
Int_t ww,
Int_t wh )
however, dpi can not be determined unless we know the size
of the canvas,for example:4inch x 3inch.
Is there any examples about this?

Best regards,
Honghu

Hi Honghu,

you can always find the best pixel to cm conversion for your usecase.

Cheers,
D