arbeit
Main Page | Namespace List | Class Hierarchy | Alphabetical List | Compound List | File List | Namespace Members | Compound Members | File Members

nrroUtil.cpp File Reference

#include "nrro.h"
#include "nrroUtil.h"
#include "nrroDispatch.h"
#include <iostream>

Go to the source code of this file.

Functions

NrroSP reshapeNrroImageA (const NrroSP nin, const vec2i size, const vec2f minPos, const vec2f maxPos, const NrroKernel &k)
 this one respects the aspect ratio (as described above)


Function Documentation

NrroSP reshapeNrroImageA const NrroSP  nin,
const vec2i  size,
const vec2f  minPos,
const vec2f  maxPos,
const NrroKernel k
 

this one respects the aspect ratio (as described above)

gota be reasonable here....

x > y

y > x

crop and padd the image to the right size, relatively speaking

resample to the actual right size

inverse Aspect ratio of image, remember that 1 is the relative size of the largest spatial axis.

Parameters:
size  size of image you want back
minPos  size of image you want back
maxPos  [0-1] min pos, relative to greatest axis
k  [0-1] max pos, relative to greatest axis

Definition at line 28 of file nrroUtil.cpp.

References Nrro::IMAGE, gutz::SmartPtr< Nrro >::isNull(), n, NrroSP, size, gutz::vec2f, and gutz::vec2f_one.

Referenced by SlicerWidget::setSlice().


Send questions, comments, and bug reports to:
jmk