|
typenames.i, double * and python: msg#00112programming.swig
I'm new to this SWIG thing, but I've been working with Python for awhile now. I'm having problems getting a double * to work with swig/python. I can get int * values to work fine, but every double * I've tried (including some examples pulled from the typenames.i file) don't seem to. I've copied my test.i, test.c, and a sample output in this message. Also, I'm using the latest Python (2.3.4rc1) and ditutils. Oh yeah, and Windows (against my will, I promise). Any ideas? test.i ------- %module test %include "typemaps.i" %types(int *, short *, long *, float *, double *); int twice(int *INPUT); double twotimes(double *INPUT); test.c -------- %module test %include "typemaps.i" %types(int *, short *, long *, float *, double *); int twice(int *INPUT); double twotimes(double *INPUT); Python session --------------------- >>> import _test >>> _test.twice(3) 6 >>> _test.twotimes(3) 1244484.0 >>> _test.twotimes(3.0) 1244484.0 _______________________________________________ Swig maillist - Swig@xxxxxxxxxxxxxxx http://mailman.cs.uchicago.edu/mailman/listinfo/swig |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | RE: Multi-arg typemap problem: 00112, Joel Wagner |
|---|---|
| Next by Date: | Re: Multi-arg typemap problem: 00112, Marcelo Matus |
| Previous by Thread: | red card !!!!!!!!!i: 00112, Devender Marri |
| Next by Thread: | Re: typenames.i, double * and python: 00112, Marcelo Matus |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |