Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Microsoft C 6.0 - <b>fmsbintoieee() convert ms binary single-precision number to ieee</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 fmsbintoieee()          Convert MS Binary Single-Precision Number to IEEE

 #include   <math.h>

 int        fmsbintoieee(msbin,ieee);
 float      *msbin;                      Pointer to MS binary
 float      *ieee;                       Pointer to IEEE float

    fmsbintoieee() converts the Microsoft binary format, 'msbin', to the
    single-precision IEEE format value 'ieee'. Float values in Microsoft
    C are normally in IEEE format.

    Returns:    0 if successful, 1 if an overflow resulted.

      Notes:    fmsbintoieee() does not handle IEEE NANs and infinities;
                in the conversion, IEEE denormals are treated as 0.

                Microsoft BASIC stores numbers in Microsoft binary
                format.

 Portability:   Applies to MS DOS only.

   -------------------------------- Example ---------------------------------

    The following statements convert a Microsoft binary float to an IEEE
    float.

            #include <math.h>
            #include <stdlib.h>              /* for perror */

            main()
            {
                float IEEE, msbin;

               if(fmsbintoieee(&msbin,&IEEE) == 1)
                     perror("OVERFLOW CONVERTING TO IEEE");
           }


See Also: fieeetomsbin() dieeetomsbin() dmsbintoieee()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson