OpenCores
URL https://opencores.org/ocsvn/raytrac/raytrac/trunk

Subversion Repositories raytrac

[/] [raytrac/] [trunk/] [utils/] [memMaker.c] - Diff between revs 75 and 79

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 75 Rev 79
Line 33... Line 33...
        char *end;
        char *end;
        int R;
        int R;
 
 
        int offset;
        int offset;
 
 
 
 
}memparam={0,0,0,australia,canada,0,1};
}memparam={0,0,0,australia,canada,0,1};
 
 
//mpx memparam={0,0,australia};
//mpx memparam={0,0,australia};
 
 
void optParser(int argc, char ** argv){
void optParser(int argc, char ** argv){
Line 105... Line 106...
int f0inv(float x){
int f0inv(float x){
        int I;
        int I;
        float fI;
        float fI;
        fI=(1/x);
        fI=(1/x);
        //fprintf (stdout," %f %f ", x, fI);
        //fprintf (stdout," %f %f ", x, fI);
        fI*=pow(2,memparam.dec+2);
        fI*=pow(2,memparam.dec);
        I=fI;
        I=fI;
        I&=0x3ffff;
        I&=0x3ffff;
        return I;
        return I;
}
}
 
 
int f1sqrt(float x){
int f1sqrt(float x){
        int S;
        int S;
        float fS;
        float fS;
        fS=(sqrt(x)*pow(2,memparam.dec+2));
        fS=(sqrt(x)*pow(2,memparam.dec));
        S=fS;
        S=fS;
        S&=0x3ffff;
        S&=0x3ffff;
        return S;
        return S;
}
}
 
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.