IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Opened 22 years ago

Closed 22 years ago

Last modified 21 years ago

#163 closed enhancement (later)

Need wrappers for psMetadataAdd for the sake of SWIG

Reported by: rhl@… Owned by: Paul Price
Priority: high Milestone:
Component: sys Version: unspecified
Severity: minor Keywords:
Cc:

Description

SWIG cannot handle varargs functions (googling "SWIG varargs" finds an explanation from
SWIG's author).

In consequence, we need wrappers for psMetadataAdd for the various data types if we
are to use them from e.g. python:

/
*
*/
/*

  • SWIG doesn't like varargs functions; so provide non-varargs versions of psMetadataAdd */

bool psMetadataAddF32(psMetadata* restrict md, int where, const char *name, const char *comment,
float val)
{

return psMetadataAdd(md, where, name, PS_META_F32, comment, val);

}

bool psMetadataAddF64(psMetadata* restrict md, int where, const char *name, const char *comment,
double val)
{

return psMetadataAdd(md, where, name, PS_META_F64, comment, val);

}

bool psMetadataAddS32(psMetadata* restrict md, int where, const char *name, const char *comment,
int val)
{

return psMetadataAdd(md, where, name, PS_META_S32, comment, val);

}

bool psMetadataAddStr(psMetadata* restrict md, int where, const char *name, const char *comment,
char *val)
{

return psMetadataAdd(md, where, name, PS_META_STR, comment, val);

}

Change History (2)

comment:1 by Paul Price, 22 years ago

Resolution: later
Status: newclosed

We'll worry about SWIG later.

comment:2 by Eric.VanAlst@…, 21 years ago

Alpha release 5 contains SWIG interface for psLib.

Note: See TracTickets for help on using tickets.