Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jan 6, 2006, 6:19:30 PM (18 years ago)
Author:
rennerc
Message:

some more entities should sync now

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/network/src/subprojects/network/network_unit_test.cc

    r6341 r6419  
    136136
    137137  /* create a server stream */
    138   nm->createServer(*serverSync, port);
     138  nm->createServer(port);
    139139
    140140  /* esatblish a connection */
     
    289289  printf("%f = ", f);
    290290  printf(s); printf("\n");
    291  
     291
    292292  byte* res = Converter::floatToByteArray(f);
    293293  printf("Byte Array: ");
     
    295295    printf("%i  ", res[i]);
    296296  printf("\n");
    297  
     297
    298298  float b = Converter::byteArrayToFloat(res);
    299299  printf("ReConvert: %f \n", b);
     
    305305  printf("### %f = ", f);
    306306  printf(s); printf("\n");
    307  
     307
    308308  byte* res = Converter::_floatToByteArray(f);
    309309  printf("Byte Array: ");
     
    311311    printf("%i  ", res[i]);
    312312  printf("\n");
    313  
     313
    314314  float b = Converter::_byteArrayToFloat(res);
    315315  printf("ReConvert: %f \n", b);
     
    324324    printf("%i  ", res[i]);
    325325  printf("\n");
    326  
     326
    327327  int z = Converter::byteArrayToInt(res);
    328  
     328
    329329  printf("ReConvert: %i\n", z);
    330330
    331  
     331
    332332  //float a = 5.4f;
    333333  //float b = 2.0f;
    334334  //printf("%f mod %f = %f", a, b, a % b);
    335  
    336   printf("\n");
    337  
     335
     336  printf("\n");
     337
    338338  */
    339339  /*
    340340  float y;
    341341  char* s;
    342  
     342
    343343  y = 12.0f;
    344344  s = Converter::floatToBinString(y);
    345345  printf("%f = ", y);
    346346  printf(s); printf("\n");
    347  
     347
    348348  y = 24549026.0f;
    349349  s = Converter::floatToBinString(y);
    350350  printf("%f = ", y);
    351351  printf(s); printf("\n");
    352  
     352
    353353  y = 12.4e20f;
    354354  s = Converter::floatToBinString(y);
    355355  printf("%f = ", y);
    356356  printf(s); printf("\n");
    357  
     357
    358358  y = 4.7824f;
    359359  s = Converter::floatToBinString(y);
    360360  printf("%f = ", y);
    361361  printf(s); printf("\n");
    362  
     362
    363363  y = -4.7824f;
    364364  s = Converter::floatToBinString(y);
    365365  printf("%f = ", y);
    366366  printf(s); printf("\n");
    367  
     367
    368368  y = -14.35e14f;
    369369  s = Converter::floatToBinString(y);
     
    371371  printf(s); printf("\n");
    372372                                                            */
    373  
    374  
     373
     374
    375375  /*
    376376  float a = 12.3f;
    377  
     377
    378378  char* s = Converter::floatToBinString(a);
    379379  printf("%f = ", a);
    380380  printf(s); printf("\n");
    381  
     381
    382382  byte* res = Converter::floatToByteArray(a);
    383383  printf("Byte Array: \n");
     
    385385    printf("%i  ", res[i]);
    386386  printf("\n");
    387  
     387
    388388  float b = Converter::byteArrayToFloat(res);
    389389  printf("ReConvert: %f \n", b);
     
    392392//  testFloatConverter(134.26455646546548741661675165f); printf("\n");
    393393 // testFloatConverter(35.67e14f); printf("\n");
    394  
     394
    395395  testFloatConverter(12.3e-7f); printf("\n");
    396396  testFloatConverter(134.26455646546548741661675165f); printf("\n");
    397397  testFloatConverter(35.67e14f); printf("\n");
    398  
     398
    399399  return 0;
    400400}
Note: See TracChangeset for help on using the changeset viewer.