1 |
|
5 |
#include <stdio.h>
|
2 |
|
|
#include <string.h>
|
3 |
|
|
#include <math.h>
|
4 |
|
|
#include "m3d_struct.h"
|
5 |
|
|
#include "m3d_const.h"
|
6 |
|
|
#include "m3d_hotes.h"
|
7 |
|
|
#include "m3d_erreur.h"
|
8 |
|
|
#include "prototype.h"
|
9 |
|
|
#include <cstdlib>
|
10 |
|
|
void m3d_convfd(char *line,float *resu)
|
11 |
|
|
{
|
12 |
|
|
char temp[256] ;
|
13 |
|
|
int i ;
|
14 |
|
|
|
15 |
|
|
|
16 |
|
|
temp[0] = 0 ;
|
17 |
|
|
i = 0 ;
|
18 |
|
|
while (strncmp(line+i,"\0",1))
|
19 |
|
|
{
|
20 |
|
|
if (!strncmp(line+i,"D",1))
|
21 |
|
|
{
|
22 |
|
|
strncat(temp,"e",1) ;
|
23 |
|
|
}
|
24 |
|
|
else strncat(temp,line+i,1) ;
|
25 |
|
|
i++ ;
|
26 |
|
|
}
|
27 |
|
|
strncat(temp,"\0",1) ;
|
28 |
|
|
*resu = (float)atof(temp) ;
|
29 |
|
|
return ;
|
30 |
|
|
}
|