Mercurial > hg > orthanc
comparison Core/Images/ImageProcessing.h @ 4082:2e1564f57542
ImageProcessing::FitSizeKeepAspectRatio()
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Tue, 23 Jun 2020 07:39:23 +0200 |
parents | 73c22208272f |
children |
comparison
equal
deleted
inserted
replaced
4080:f18eaade6153 | 4082:2e1564f57542 |
---|---|
198 | 198 |
199 static void SmoothGaussian5x5(ImageAccessor& image); | 199 static void SmoothGaussian5x5(ImageAccessor& image); |
200 | 200 |
201 static void FitSize(ImageAccessor& target, | 201 static void FitSize(ImageAccessor& target, |
202 const ImageAccessor& source); | 202 const ImageAccessor& source); |
203 | 203 |
204 // Resize the image to the given width/height. The resized image | |
205 // occupies the entire canvas (aspect ratio is not preserved). | |
204 static ImageAccessor* FitSize(const ImageAccessor& source, | 206 static ImageAccessor* FitSize(const ImageAccessor& source, |
205 unsigned int width, | 207 unsigned int width, |
206 unsigned int height); | 208 unsigned int height); |
209 | |
210 // Resize an image, but keeps its original aspect ratio. Zeros are | |
211 // added around the image to reach the specified size. | |
212 static ImageAccessor* FitSizeKeepAspectRatio(const ImageAccessor& source, | |
213 unsigned int width, | |
214 unsigned int height); | |
207 }; | 215 }; |
208 } | 216 } |
209 |