Possible loss of data error message when build project

This is a discussion on Possible loss of data error message when build project within the C Programming forums, part of the General Programming Boards category; Hi all, I have gotten my hands on this open-source C/C++ library. They have all the source files and some ...

  1. #1
    Registered User
    Join Date
    Jul 2007
    Posts
    16

    Possible loss of data error message when build project

    Hi all,

    I have gotten my hands on this open-source C/C++ library. They have all the source files and some test and demo files for us to use.

    So at first i tried to create my own project and set it as the startup project and with the dependancy on the library. However i get this error when i try to build:

    c:\blepo\src\Image\ImageAlgorithms.h(525): warning C4244: 'argument' : conversion from 'KLT_locType' to 'int', possible loss of data

    There are demos which are already built into exe and i managed to run them. So i am wondering what is it wrong that i am doing?

    I have already set the environment variables.. at path. I also copied the assembler exe into windows\system32 folder. In Visual Studio .Net 2003, i have also set the library's external\bin under the "Project --> VC++ Directories" in the include.

    Anyone can explain to me what might the error message means?

    Thanks!

    Regards,

    ang_ks.

  2. #2
    Software Developer jverkoey's Avatar
    Join Date
    Feb 2003
    Location
    University of Waterloo
    Posts
    1,904
    You aren't doing anything wrong. The warning that is being displayed by Visual Studio is just that: a warning. The warning itself is pretty obvious (if you want to see an easy example in action, convert a double to an int without an explicit cast).

    So basically, don't worry about it. If that's the only notification you received, then your project is fine.

  3. #3
    Registered User
    Join Date
    Jul 2007
    Posts
    16
    okay... i see what you mean.. reading throught the "C++ Programming/Type Casting" on wikipedia.

    The thing is the error comes from a header file in the open source library i mentioned. Should i even try to edit it?

  4. #4
    Software Developer jverkoey's Avatar
    Join Date
    Feb 2003
    Location
    University of Waterloo
    Posts
    1,904
    If it's really bugging you you can either 1) disable that warning or 2) fix the code. My advice would be to go with 2, seeing as it is such a minor warning.

  5. #5
    Registered User
    Join Date
    Jul 2007
    Posts
    16
    because it is a library file i am assuming that it should be error-free (since other people are using it just fine).

    disabling the warning... how do it do that? does that allow the construction of the exe file? because with that error, i cannot build the exe and run the project.

    i will try to fix the error too since it is a minor error... but keep in mind... minor or not is relative to who is facing the problem..

    sorry if i have too many questions..
    Last edited by ang_ks; 07-11-2007 at 12:07 AM.

  6. #6
    Captain Crash brewbuck's Avatar
    Join Date
    Mar 2007
    Location
    Portland, OR
    Posts
    7,274
    Quote Originally Posted by ang_ks View Post
    because it is a library file i am assuming that it should be error-free (since other people are using it just fine).
    A warning is not an error.

  7. #7
    Registered User
    Join Date
    Jul 2007
    Posts
    16
    Oh... how ignorant i am......

    okay, after all the blasting with questions... refreshing with C syntax... i finally sum up to this:

    I have to use Directshow API to do my image and video tasks (using Creative Webcam Live!)

    Then use the header files from the hardware-in-the-loop to write to the 'write shared memory' functions.

    Here are my new questions:

    I am using Visual Studio .NET 2003. But i don't have the installation files for the MSDN library. At the online documentation, i get kind of confused which i am supposed to refer to for Directshow. Under Win32 and COM development? It is suitable for all types of compilers?

    Next question is, what SDK i need to install. I have downloaded the "dxsdk_jun2007.exe" but everything i run it... the installation bar.. when it reaches the third bar.. it just restarts itself. Am i using the wrong file? If i am which am i supposed to download? Platform SDK?

    Thnx again to all.

    Regards.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. xor linked list
    By adramalech in forum C Programming
    Replies: 23
    Last Post: 10-14-2008, 11:13 AM
  2. Problem Displaying a Struct
    By rockstarpirate in forum C++ Programming
    Replies: 16
    Last Post: 05-05-2008, 10:05 AM
  3. Using malloc
    By ulillillia in forum C Programming
    Replies: 34
    Last Post: 02-20-2008, 06:41 PM
  4. singly linked circular list
    By DarkDot in forum C++ Programming
    Replies: 0
    Last Post: 04-24-2007, 09:55 PM
  5. How to build a C project?
    By jumpjack in forum C Programming
    Replies: 5
    Last Post: 01-26-2006, 07:35 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21