#251 closed defect (fixed)
Function psSpline1DAllocGeneric bounds type
| Reported by: | Owned by: | Paul Price | |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | PSLib SDRS | Version: | unspecified |
| Severity: | minor | Keywords: | |
| Cc: |
Description
In SDR-10 section 4.4.2, the function psSpline1DAllocGeneric specifies a
psVector bounds to indicate the knots to be used. Currently the code assumes
this vector is of type PS_TYPE_F32. Should the function be capable of handling
different types for bounds? Should an update to the document be made to clarify
what the input vector bounds type should be?
Note:
See TracTickets
for help on using tickets.

Good point. How about we change "float *knots" to "psVector *knots", which
gives us flexibility in the type, and specify types U32, F32 and F64?
Updated SDRS:
typedef struct {
piece. Size is n+1.
} psSpline1D;
The \code{psSpline1D} structure consists of an array of \code{n}
polynomials, which are the spline pieces. Note that this means that
the spline pieces may, in general, be of any order. \textbf{For the
present, we shall restrict the order of the polynomials to either 1
(linear) or 3 (cubic).} All the spline pieces shall have the same
order polynomial (the type of polynomial is left to the
implementation). The \code{knots} member specifies the boundaries
between each spline piece (including the two ends). The \code{knots}
vector may be of type U32, F32 or F64.