CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com

Search:

Type: Posts; User: karnavor

Page 1 of 3 1 2 3

Search: Search took 0.01 seconds.

  1. Replies
    1
    Views
    177

    When to use static classes

    Hello,

    I am just wondering what the best practice is for when to use static classes (by static class, I mean a class which has only static attributes and functions).

    If you are creating more...
  2. Replies
    10
    Views
    561

    General Object-Orientated Question

    Hello,

    I have a very general question about object-orientation programming. I have been programming for a few years, but I'm just wondering what the best practice is for this particular situation....
  3. Renaming Visual Studio Project/Solution Files

    Hello,

    I have a Visual Studio 10 Project, and I want to rename both the Project, and the Solution. To do this so far, I have right-clicked on the Project or Solution in the Solution Explorer, then...
  4. fstream - Writing in the middle of a file

    Hello,

    I want to edit the contents of a file using fstream, but none of the modes in the fstream constructor work for me.

    If I use ios::trunc, then the whole file is deleted - but I want to...
  5. Replies
    0
    Views
    298

    Adding GPS data to JPEG file

    Hello,

    This is not strictly a C++ question, but I don't know where else to ask!

    Anyway, I am writing a program to read and write EXIF data in a JPEG file; specifically, the GPS data.

    I have...
  6. Replies
    2
    Views
    1,841

    OpenCV solve equation

    Hello,

    I'm hoping that there is somebody out there who is familiar with OpenCV, as I have a very simple problem.

    I have a linear equation Ax = B which I want to solve. This is done with the...
  7. Replies
    2
    Views
    421

    Linking to DLLs with Visual Studio 10

    Hello,

    I have a library that I want to link to with Visual Studio 10. It is a dynamic-link library, with a .dll file and a .lib file. I am following what I think is the correct procedure for...
  8. Replies
    3
    Views
    758

    Compiling from source

    Hello,

    I have a fairly basic question about compiling libraries. Suppose that I want to use an open-source library that has been written by somebody else. Typically, when I go to the website to...
  9. Thread: ios::trunc

    by karnavor
    Replies
    8
    Views
    2,252

    Re: ios::trunc

    But is it possible to write the vector.size() value at the beginning of the file, after I've written the rest of the file?
  10. Thread: ios::trunc

    by karnavor
    Replies
    8
    Views
    2,252

    Re: ios::trunc

    The reason I need that piece of code is because I need to read the last entry in the data file, before I read the rest of the file. When creating the file, I am adding numbers from an array to the...
  11. Thread: ios::trunc

    by karnavor
    Replies
    8
    Views
    2,252

    Re: ios::trunc

    Hi,

    Thanks for your help. Losing the ios::app worked!

    However, I have also come across something else peculiar.

    If I use:


    in.seekg(-(sizeof(int)), ios::end);
  12. Thread: ios::trunc

    by karnavor
    Replies
    8
    Views
    2,252

    ios::trunc

    Hello,

    I am saving data to a file "myfile.dat". Every time I save new data, I want to eliminate the existing file and start a new file. From what I know, setting the ios::trunc flag should do...
  13. Replies
    4
    Views
    682

    Re: GNU Scientific Library eigenvectors

    Hi, thanks for your reply. The Wikipedia article states that:

    "the Perron–Frobenius theorem ... asserts that a real square matrix with positive entries has a unique largest real eigenvalue and...
  14. Replies
    4
    Views
    682

    GNU Scientific Library eigenvectors

    Hello,

    I am trying to use the GNU Scientific Library (GSL) to compute the leading eigenvector (corresponding to the largest eigenvalue) of a matrix M of size N (N ~ 100). M is square and...
  15. Replies
    1
    Views
    435

    Clearing std::cin buffer?

    Hello,

    I am using a computer vision C++ library called OpenCV, which has a function "int waitKey(int delay)". This function waits for a user input key, for a specified number of milliseconds. It...
  16. Replies
    4
    Views
    1,065

    Programming Windows API in Mac OS Bootcamp

    Hello,

    I am running Windows 7 on a Mac, using Apple's Bootcamp utility, such that the Windows installation is native. However, I am finding some issues when programming the Windows API using...
  17. Thread: Header files

    by karnavor
    Replies
    2
    Views
    311

    Header files

    Hello,

    What is the difference between the header files <header.h> and <header>?

    I know that the <...> brackets indicate that the header file is located in some standard directory that the...
  18. Replies
    2
    Views
    2,068

    ifstream / ofstream precision

    Hello,

    I'd like to ask two different questions on a related topic please...

    1. When I am writing float data to a text file, I want to set the precision. I know that with std::cout, you can...
  19. Replies
    3
    Views
    653

    Self-referencing header files

    Hello,

    I have two classes, Class1 and Class2, declared in two header files, "class1.h" and "class2.h". Each class contains a member instance of the other class. If I #include the necessary header...
  20. Replies
    2
    Views
    466

    Initializing length of std::vector

    Hello,

    I know that when writing a class declaration, if the class contains an array of fixed length, then the length of that array can be initialized in the class declaration, without having to do...
  21. Replies
    1
    Views
    328

    .lib and .dll files

    Hello,

    I'm sure this is a very simple issue, but it is confusing me a lot right now. So I am writing a program which uses a .dll file and a .lib file. I don't know much about these, but from what...
  22. Re: "Access violation" when assigning matrix values

    Hi,

    Thanks - I managed to fix it by using cvmSet(), which seems to automatically convert to a float.

    However, I am now having an issue with the "status" matrix. I want to print out the...
  23. "Access violation" when assigning matrix values

    Hello,

    I am writing a program to estimate the fundamental matrix between two images, using OpenCV. This is a computer vision technique, but the error I am getting is something to do with memory in...
  24. Thread: OpenCV Matrix

    by karnavor
    Replies
    1
    Views
    1,754

    OpenCV Matrix

    Hello,

    Hopefully somebody on here is familiar with OpenCV....

    I am using OpenCV to try to create a 20 x 2 matrix, with floating point elements, and assign the first element of the matrix to...
  25. Thread: User Controls

    by karnavor
    Replies
    1
    Views
    816

    User Controls

    Hello,

    I wanted to create a custom control in Visual Studio, and then add it as a component to a form. So, I added a new "User Control" to the project, and edited it by dragging and dropping...
Results 1 to 25 of 61
Page 1 of 3 1 2 3



HTML5 Development Center

Click Here to Expand Forum to Full Width