Thread: Configurations give different results

  1. #1
    Registered User
    Join Date
    Feb 2002
    Posts
    32

    Configurations give different results

    I've been working on a graphics project for a couple of weeks now where I handle transformations, polygon filling, light calculations, z-buffer etc. without using any API or third party libraries.
    I've been buiding this project in Visual C++ 6.0 with the Platform SDK from October
    When I build my project in the debug config I can't see anything but my ambient lights. If I build my project in the Release config, I can see specular,diffuse and ambient from one of my lights.
    However, If I press the GO button while I am in the release configuration I can see every component from every light.

    The code in itself does not check for different configurations what so ever. It is also single threaded so there shouldn't be any race conditions wich are altered at different optimisation.

    Does anyone have any idea of what might be going on here?

  2. #2
    Registered User Codeplug's Avatar
    Join Date
    Mar 2003
    Posts
    4,981
    Do a build->clean, build->rebuild all and post all your warnings.

    gg

  3. #3
    Registered User
    Join Date
    Feb 2002
    Posts
    32
    I made a new project from scratch, (same source files). And now I don't have to press GO anymore But debug mode still looks strange. These are my warnings. It doesn't really matter since the project works fine now and I don't need to debug it anymore. But it would be nice to understand it


    Code:
    Deleting intermediate files and output files for project 'kladd_GL - Win32 Release'.
    --------------------Configuration: kladd_GL - Win32 Release--------------------
    Compiling resources...
    Compiling...
    draw_triangle.cpp
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\vector2.h(56) : warning C4244: 'return' : conversion from 'double' to 'float', possible loss of data
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\vector3.h(65) : warning C4244: 'return' : conversion from 'double' to 'float', possible loss of data
    engine.cpp
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\engine.cpp(14) : warning C4800: 'int' : forcing value to bool 'true' or 'false' (performance warning)
    globals.cpp
    kladd.cpp
    matrix4.cpp
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\vector2.h(56) : warning C4244: 'return' : conversion from 'double' to 'float', possible loss of data
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\vector3.h(65) : warning C4244: 'return' : conversion from 'double' to 'float', possible loss of data
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\matrix4.cpp(83) : warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\matrix4.cpp(84) : warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\matrix4.cpp(85) : warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\matrix4.cpp(86) : warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\matrix4.cpp(88) : warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\matrix4.cpp(89) : warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\matrix4.cpp(90) : warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\matrix4.cpp(91) : warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\matrix4.cpp(93) : warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\matrix4.cpp(94) : warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\matrix4.cpp(95) : warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\matrix4.cpp(96) : warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
    midpoint.cpp
    nff_load.cpp
    object.cpp
    transformations.cpp
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\vector2.h(56) : warning C4244: 'return' : conversion from 'double' to 'float', possible loss of data
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\vector3.h(65) : warning C4244: 'return' : conversion from 'double' to 'float', possible loss of data
    C:\Documents and Settings\Fredrik\Kod\kladd_GL\transformations.cpp(106) : warning C4305: 'argument' : truncation from 'const double' to 'float'
    triangle.cpp
    Linking...
    
    kladd_GL.exe - 0 error(s), 20 warning(s)

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. 72hour GDC Results
    By jverkoey in forum A Brief History of Cprogramming.com
    Replies: 3
    Last Post: 07-05-2004, 11:46 PM
  2. Replies: 1
    Last Post: 06-29-2004, 05:23 PM
  3. Why dont 56k modems give 56kbps?
    By MovingFulcrum in forum A Brief History of Cprogramming.com
    Replies: 16
    Last Post: 04-24-2002, 08:15 AM
  4. Radiohead rule
    By Brian in forum A Brief History of Cprogramming.com
    Replies: 2
    Last Post: 01-18-2002, 07:37 PM
  5. How To Give A Font Colour ?
    By Unregistered in forum Windows Programming
    Replies: 1
    Last Post: 09-14-2001, 01:22 PM