General C++ Programming - June 2011 (Page 20)

Allegro Animation <help me>
 
/* When this program runs for a certain period of time, it calls abort() and ends with a user abort prompt */ /* built using visual c++ */ #define USE_CON...
[16 replies] Last: K. I'll try soon. Really doesnt madder, but i just wonder why its scre... (by Dabeast45)
by auras
Same class for inheriting and private member
 
Hello all, I would like to know if it is possible to create a class Y which at the same time: 1) inherits from a class X 2) has a private member of class X...
[4 replies] Last: @ isnork That is illegal, and defeats the purpose of private storag... (by Duthomhas)
by ramako
fstream and reading text (linux)
 
Hi guys, I have a program that makes a txt, and I am trying to read the contents from that txt and put it into a vector. The first line in the file is MP-PER...
[1 reply] : So, let's say i is 0. You put stuff into the vector at i (0), then inc... (by LB)
Calling Matlab Script from VC++ 2008
 
I have Matlab Scripts (.m) files that take data written into .txt files by VC++, graphs them, and saves them as .jpgs. I would like to be able to call these ...
[1 reply] : I have in the past turned Matlab functions (not scripts, but fnuctions... (by Moschops)
by redY
C++ jump
 
I need a simple solution to this: void a(){ x++; a(); } This obviously is a call. I need a jump, since the call inevitably ends after 700k steps with s...
[16 replies] Last: Thank you very much for the answer and for your time, I'll try it. (by redY)
by jorgen
Problem using gmp
 
I want to use gmp from the standard library and try this program: using namespace std; #include <gmp.h> int main() { mpf_t x; mpf_init(x); re...
[2 replies] Last: Works like a charm, thanks! (by jorgen)
Help declaring two classes dependent on eachother.
 
Hi! I have a problem regarding two classes that are dependent on eachother in their definition. What I'm trying to acomplish is the following; A.h: #i...
[7 replies] Last: Sorry, I missed to input the include guards. They are there already. I... (by Bobruisk)
problem about boost::serialization library
 
i am using boost serialization library. I have a child class deriving from parent class. Both classes have their serialization function. When I want to hold a c...
[1 reply] : Your save() and load() functions must be virtual (at least in your cla... (by coder777)
Can't Access Vector's Values After Inserting Values
 
Hi guys , Given the following code : class Pizza { protected: virtual void someFunction(ostream& someOutput) const = 0 ; public: Pizza(); virtual ~Pizza(...
[2 replies] Last: i dont know why you insert pointer from void Order::addNewPizza() ... (by namelij)
playing audio files in c++
 
hi , i am making a very basic game , using opengl library in c++. i need to play some audio files for my charachters in the game .The audio files need to play...
[1 reply] : You probably should be using a game lib like SFML. With it, it's as s... (by Disch)
What is the difference between using malloc and free versus new and delete?
 
What is the difference between using malloc and free versus new and delete, specially when dealing with pointers.
[5 replies] Last: Dynamic Object Initialisation consists of the various steps: 1)Alloca... (by Adee)
some questions about pointer to struct
 
Hi, I am having trouble understanding the following code on page 318 in Thinking in C++: #include <iostream> using namespace std; union U { ...
[2 replies] Last: What is the problem??Can you please be more specific in your question?... (by Adee)
NEED URGENT HELP PLEASE REPLY ASAP
 
#include <iostream> #include <string> #include<stdlib.h> #include<windows.h> #include <stdio.h> #include <conio.h> #include <stdlib.h> #include <cstdl...
[5 replies] Last: Nvm i figured out the problem see the becakets are not done properly s... (by kingviser)
Socket on wrong port
 
From Server if((sockfd = socket(PF_INET, SOCK_STREAM, 0)) == -1) fatal("in socket"); if(setsockopt(sockfd, SOL_SOCKET, SO_REUSEADDR, &yes, sizeof(int))...
[11 replies] Last: through the net The internet or your lan? (by ultifinitus)
An array definition I'm unfamiliar with
 
Hi all, I've been around C++ for a while but I'm trying to understand some code in C and there's some syntax I can't figure out. Ok, so I have a file with...
[2 replies] Last: Just a silly idea, but having done some reverse engineering myself, it... (by kev82)
Problem with programming
 
// Menu Chooser // Demonstrates the switch statement #include <iostream> #include <string> #include<stdlib.h> #include<windows.h> #include <stdio.h> #...
[no replies]
Looping problem
 
Im working on an assignment and having trouble with it. The code I have so far is written below. Im confused about how to have a user cin an initial amount, cin...
[6 replies] Last: hope this helps #include <iostream> // #include <fstream> using name... (by Bongoman)
Using Linked list
 
Hi I need to create a simple program using linked list only.Anyone please help me in this regard.It's very much appreciable if you could can do the program. ...
[1 reply] : [quote=bharadwajuma]It's very much appreciable if you could can do the... (by closed account zb0S216C)
event listeners
 
Haven't really used anything like this in c++ before, but I know Java has something like this so I figure it's gotta be in c++ some where. So I'm in a method...
[2 replies] Last: What you could do is have a separate process thread that spins( waits ... (by closed account zb0S216C)
by HenriK
What does this do/mean?
 
Hello, it´s me here. I was trying to learn how to use DirectX and XInput when I accidentally found this kind of marking in a piece of code: function (). som...
[1 reply] : If the function returns an object that has the something method/fiel... (by webJose)
June 2011 Pages: 1... 1819202122... 28
  Archived months: [may2011] [jul2011]

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