try
{
Blob blob(static_cast<const void*>(buf), stStat.st_size);
Geometry geo(22,22);
Image image( blob );
image.zoom(geo);
image.write("2.jpg");
}
catch( Exception &error_ )
{
cout << "Caught exception: " << error_.what() << endl;
return -1;
}
but i get a 22X17 picutre,how can i get a 22x22 picture?
i can't zoom a picture to the specified width and height
Re: i can't zoom a picture to the specified width and height
i got it, use 22x22! or geo.aspect(ture);