IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Opened 22 years ago

Closed 22 years ago

Last modified 22 years ago

#43 closed enhancement (fixed)

psVectorFFT/psImageFFT direction parameter should be bool

Reported by: robert.desonia@… Owned by: eugene
Priority: high Milestone:
Component: PSLib SDRS Version: unspecified
Severity: minor Keywords:
Cc:

Description

I suggest that the direction parameter of psVectorFFT/psImageFFT be changed to
bool instead of int as only two options really exist: forward or reverse.

Could also change the parameter name to 'isForward' to make it easy to figure
out that TRUE is forward.

-rdd

Change History (3)

comment:1 by robert.desonia@…, 22 years ago

Given the issue of communicating if a real-result is desired for an IFFT or not,
I suggest that the direction parameter be converted to a bit flag with the
following enum driving it:

typedef enum {

PS_FFT_FORWARD = 0, /< psImageFFT/psVectorFFT should

perform a forward FFT.

PS_FFT_REVERSE = 1, /< psImageFFT/psVectorFFT should

perform a reverse FFT.

PS_FFT_REAL_RESULT = 2

/< psImageFFT/psVectorFFT should return a real image.

This is valid for

  • only reverse FFT, i.e., the psImageFFT/psVectorFFT

flag parameter

  • should appear as PS_FFT_REVERSE+PS_FFT_REAL_RESULT. */

} psFftFlags;

comment:2 by robert.desonia@…, 22 years ago

Sorry for the poor line-wrapping of the last post.

Basically, a forward FFT would look like:

out = psImageFFT(in,PS_FFT_FORWARD);

a reverse FFT would look like:

out = psImageFFT(in,PS_FFT_REVERSE);

and a reverse FFT with a real resultant would look like:

out = psImageFFT(in,PS_FFT_REVERSE+PS_FFT_REAL_RESULT);
(or, if you prefer bitwise operators)
out = psImageFFT(in,PS_FFT_REVERSE | PS_FFT_REAL_RESULT);

comment:3 by Paul Price, 22 years ago

Resolution: fixed
Status: newclosed

Suggested implemented in SDRS.

Note: See TracTickets for help on using tickets.