General C++ Programming - January 2012 (Page 24)

Help with setting up directx sdk with c++
 
I've set up the paths for the sdk(using visual c++) but when I use any of the sample codes from the sdk I get errors. Do I need to include anything else? I h...
[10 replies] Last: Here is an example from my comp: C:\Program Files (x86)\Microsoft Di... (by codekiddy)
Visual c++ cannot find "resource.h"
 
When ever I compile my project it cannot not find the "resource.h" I have directx sdk and windows sdk include files and lib files already included but why ca...
[2 replies] Last: Normally resource.h is where you write your long, long long list of #d... (by LB)
Crash with structs loaded from file?
 
Okay so I was originally working on VB.Net 2010 and I was able to load the file successfully. Now I'm trying to load the file in C++ and its not working out. Th...
[3 replies] Last: In here if (s[s.length() - 1 ] == '"') s.erase(s.length() - 1,s.lengt... (by not2betrusted2)
selection sort
 
Hi, I am trying to get my selection sort to work and I wanted to debug to ensure it's printing the correct current smallest element, but it's just an infinite l...
[6 replies] Last: Did you notice that I updated my previous post? You should always call... (by Peter87)
How do I create a random number of some distribution in Visual C++?
 
I haven't found any clear and concise information on this specific topic, so I'd like to ask this relatively simple question for myself and anyone else who come...
[6 replies] Last: Thanks :) RE rand_s() ; I have it on good authority that the Visua... (by ausairman)
int and long
 
I am using Windows 7 64-bit and at first I didn't know why when I used sizeof for an int variable and a long variable, the output to console was 4 bytes, then I...
[5 replies] Last: I think the wikipedia article simply named "64-bit" gives a very good ... (by Cubbi)
Help with include file
 
When ever I compile my project it cannot not find the resource.h I have directx sdk and windows sdk include files and lib files already included but why can...
[1 reply] : http://www.cplusplus.com/forum/general/59234/ (by codekiddy)
by lolfoo
Checking if a point is inside a circumference?
 
enter radius: enter x: enter y: enter x for the point to test for: enter y for the point to test for: So how do i check to see if the point is inside the...
[1 reply] : Check if the distance between the point and the center of the circle i... (by Peter87)
by bruice
Vector <int , 2> i
 
As we all know, vector is a kind of sequence container. there are declared like that: vector<type> variable_name (number_of_elements); however, I saw a prog...
[1 reply] : Sounds like a typo from array, as in std::array<int, 2> i; , in whic... (by Cubbi)
Xor encryption
 
Hello there, I made a simple xor encryption algorithm. Now i hve this small question: can i use xor encryption to encrypt ANY file i want, or only plaintext?
[3 replies] Last: You should read the file in binary mode. Don't use getline because tha... (by Peter87)
Use a shared library in a project (CodeBlocks)
 
Hello everybody This one goes for those using CodeBlocks (but not only) So, I have this GUI project and I want to create a shared library then include it in t...
[1 reply] : I found my answer here already: http://www.devimperium.info/c_plus_plu... (by alexbnc)
Dereferencing Confusion
 
The below is an array of pointers, and a pointer to the array of pointers. Currently I'm getting segfault. The pointers point to members of another array. p....
[7 replies] Last: The solution WebJose posted seems to have worked; I did check your sol... (by tescrin)
32 bit & 64 bit optimization?
 
Question: How can I make programs that run better for different operating systems? (64bit and 32 bit) I know that 64 bit programs are supposed to be faster o...
[2 replies] Last: False rumor. The compiler may run faster if it is a 64-bit compiler, b... (by LB)
confusion with char and pointer char
 
Hi, I am a little confused with difference and usefulness of: char list vs char *list Is is that the first you must declare size of array (c-string is th...
[9 replies] Last: I have only ever used character arrays when I need an array of values ... (by LB)
by Tresky
Mandelbrot Fractal
 
I've searched Google and looked at many pages, but no one really explains it well. Could someone try to explain to me how the Mandelbrot Set works and how to us...
[2 replies] Last: Oh. Okay, so you would just simply calculate calculate how far away an... (by Tresky)
SFML C++ polygon wont change position
 
Hi Ive made a polygon collision detection function and I want to test it, but in SFML when I use the shape.Move(x,y) it seems that only the view mode is chan...
[no replies]
why do i get this error?
 
http://s1236.photobucket.com/albums/ff451/threatn/?action=view&current=Capture3213.png why do i the curly red underline for clrscr()??? btw i am using visual s...
[12 replies] Last: The code is C, compiled with a C++ compiler. conio.h is a non-standa... (by closed account 1vRz3TCk)
Word Error Rate
 
Hi, I was wondering if there is anything in C++ that deals with sentence matching and scoring, without building with counting string locations. I need to develo...
[4 replies] Last: andywestken nailed it. I should have googled natural language ... I ... (by ITPhoenix)
Urgent!!C++ task solution needed.
 
Task 2 Develop a C++ application which will perform the following tasks: • prompt the user to input a list of positive integer numbers. The total number...
[12 replies] Last: [quote=raheel92]Thanks for not cooperating :/ You could have at least ... (by webJose)
Moving Sun behind Mountains
 
Hello there i use Graphic library and draw mountains and sun. i want move sun behind mountains and come out. but i have prob for that, because sun come front o...
[7 replies] Last: The code for those of you unable to download: #include<dos.h> #inclu... (by Disch)
January 2012 Pages: 1... 2223242526... 36
  Archived months: [dec2011] [feb2012]

This is an archived page. To post a new message, go to the current page.