Hey thanks for the reply, I got this working ok.
I used the struct declarations, then the extern declarations inside the header. Outside of the header i gave the actual definition of the struct...
Type: Posts; User: ineedmunchies
Hey thanks for the reply, I got this working ok.
I used the struct declarations, then the extern declarations inside the header. Outside of the header i gave the actual definition of the struct...
Ok so i'm trying to put together a simple graphics program, following the nehe gamedev tutorials. I'm currently trying to load in some tga graphics files to memory.
I have a header file that is...
It will be for the user to solve. Stacks appear to be exactly what I'm looking for. Thanks for the help :)
I'm looking to create a version of the url=http://en.wikipedia.org/wiki/Tower_of_Hanoi]towers of hanoi[/url] problem using C++. If your unfamiliar with the game, it involves moving hoops from one peg...
Ah very good idea, I think I'm doing exactly that.
Ha yip I was indeed, very silly little mistake. Thank you.
Hmmm now to find if I can allign centrally in the middle of the rectangle!
Hmmm...
Thank you novacain, I've tried as you have said but I still cannot get it to work properly.
It does not clear the rectangle that the text is being displayed in.
case WM_COMMAND:
...
Ok, so i've been trying to have a rectangle that fills with new text each time a button is pressed. I've got it all working except for it deleting the previous text before writing any new text, so I...
Ok so i'm just trying to clear up how different variables are stored in memory/on the stack.
Say there is a program with global variables, a function that has varibale declared within it, and a...
Ok so I've just discovered the DrawText function, I'm going to play around with that some to see if I can get it to work with the window I want :) Sorry for the silly questions, I've had to jump in...
Ok yes that does help a lot. I'm very tired today and struggling to get this done, thats why I came to ask for help.
Is messagebox not a pop up window? What I am looking to do is have a window...
Ok so I've created a windows program, it has a main window and two child windows, one of which is a button. What I want to do is for the button to run a function, and then display the results of that...
Hey thanks guys, got it working :)
"A Healthy Suit
A healthy suit kept in accordance with the amused elbow
Deceivingly the suit left
The elbow threw in place of a ugliest jam"
Ha not the...
Ok so yet another issue, I'm trying to create a function that will create a different vector for each file I read from.
void vectorize (fstream in_file, vector<string> out_vector)
{while...
Ha sorry, i just realised that and edited it as you were posting there. Thank you guys.
Ah well spotted thank you. So instead of
j<i you would suggest
EDIT::
j<strVector.size
int j=0;
for (j; j<i+1; j++){
cout << strVector[j];
cout << "\n";
Oopps sorry bit rusty.
It runs now, and prints them to screen but still throws up error. Saying that the exe has...
Ok thank you, I will try that. It works great thank you. Now i am trying to print out the strings read from the file.
#include <iostream>
#include <vector>
#include <string>
#include...
Ok so I tried working with istream iterator, and I just don't get it, so I've gone back to using loops that I understand instead.
#include <iostream>
#include <vector>
#include <string>...
Ok so I'm trying this, and I want to read from the file I have open, but surely std::ifstream is not enough? I need to give the filename somehow?
std::ifstream myfile;
myfile.open...
So your argument is in favour of using the scope operator?
Does std::vector mean that vector is a component of class std, which is included in the preprocessor directives? And this would be the...
Ha well when I said phrases I was actually talking about prepositions. And other things that need more than one word sometimes.
The format I've been given is:
A <adjective1> <noun1> <verb1>...
Well it will need to access 12 random words/phrases from 5 different lists. Would it be safe to have 5 different vectors (I'm assuming thats what is meant by that code, I'm very new to C++ I've just...
Ok, so as an assignment I have been asked to create a random poem generator.
I have been provided with the format for the poem to take so thats not an issue, what I need to work out, is how to...
Hmm well I have it running now and working with this code:
BYTE image[imagesize1];
fread(image, 1, imagesize1, fileA);
for(i=0; i<imagesize1; i++)
{
image[i]=~image[i];
}...
What about pixel, i had been defining that as char because it was one byte long, but it could be defined as BYTE couldn't it? I just remembered that its in one of the header files. I had been using...