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

by Juicej
Soil image loader problem
 
i'm using code blocks and for some reason the error only points to the closing parenthesis of the "SOIL_load_OGL_texture function.. i've tried a whole bunch of ...
[6 replies] Last: well i just found out that you have to add it to the link library befo... (by Juicej)
Crash reporting during a stack overflow exception. Unable to have QDialog exec call
 
The application that i am working on has a crash reporter associated with it. The crash reporter code is part of the main code. The crash reporter pops up a dia...
[3 replies] Last: @modoran, Thanks for the reply. It's working. Thanks. (by sajaskk43)
Trouble with Netbeans font
 
I can't seem to get the infernal thing to bolden function/class declarations. Can anyone help me?? I got to fonts/colors and go to C++ and C++/Header and it...
[2 replies] Last: eh, I got it to work... Just missed a few settings. Took me a while ... (by IWishIKnew)
counter-controlled while loop
 
hey guys help me please :) The program should be print the numbers 0 through 10, along with their values doubled and tripled. The data file contains the necess...
[1 reply] : Don't double post. http://www.cplusplus.com/forum/beginner/121030/ (by Hippogriff)
Allegro 5 Sand Game Slow
 
I've been making one of those sand games that are everywhere. I'm a beginner so the code is probably bad. The game works perfectly except whenever there is a lo...
[1 reply] : I have never worked with Allegro but I will try and give some advice. ... (by Hippogriff)
"expected unqualified id before '->' token
 
template <typename T> void BSTClass<T>::InitializeNode(ND<T> node) { node = (ND<T>)malloc(sizeof(struct node)); node->colour = "red"; node->left =...
[7 replies] Last: That worked for InitializeNode(), but once I did the same for Initial... (by maeriden)
copying pointers
 
When I have a char pointer and it's initialized to a memory position, like this: char *p p = alloc(len ) where alloc is just some buffer memory: c...
[2 replies] Last: The strcpy is fine, but why not make a standard one with a few tweaks.... (by kbw)
"template declaration of 'TD<T> tree' "
 
template <typename T> struct TD { typedef TREE<T>* type; }; template <typename T> TD<T> tree; I get the error at "TD<T> tree;" and I'm still reall...
[2 replies] Last: Actually I don't want to instantiate the template in line 8 I want to ... (by Ebamber)
Arrays in Function
 
I want to call the array from one function to another all function not a main function
[2 replies] Last: Thanks i get idea condor (by Machano)
fstream doesn't work in combination with linked lists
 
Hello Dear Community, i have got a big problem. Im about to program a RPG and, of course, the player has got an inventory. The items in this inventory are stor...
[2 replies] Last: Have you tried to look at the file you wrote using a text editor? Us... (by Duthomhas)
by Juicej
Code::Blocks problem
 
i've been working on a little school project for a few days now.. and i every things been going fine until a few days back.. every time i added code i kept bui...
[3 replies] Last: thanks alot.. but suddenly i realized that it was a new library i incl... (by Juicej)
*Really dumb Question* about polymorphism
 
Lets say classes b and c are derived from class a. Can you: 1. make a pointer of a type (a * pointer) and point that pointer at a b type object? 2 if you can, c...
[2 replies] Last: Thanks :D (by jsbrowndog2013)
initialization of pointer arrays
 
The below example is an initialization of a pointer array: char *month_name(int n) { static char *name = { "Illegal month", "Januar...
[2 replies] Last: Is the character pointer pointing to the first character in the chara... (by JewelCpp)
Unable to execute and run this prog.
 
Hi Team, Unable to execute and run this prog. Need your support to run this prog. Prog. link: http://projects.icbse.com/cpp-215
[1 reply] : What exactly is the problem you are having, what errors? (by Hippogriff)
Segmentation fault (core dumped)
 
I tried to run my program: $ cat pointers_array.txt | ./pointers_array and got this error: Segmentation fault (core dumped) I think that means there...
[1 reply] : I figured it out. It needed to be: (p = my_alloc(len)) == NULL) becau... (by johnmerlino)
by OUIJ
Is this code efficient
 
I am in my first year of coding in school. While on break I am continuing to learn C++ on my own. This is not a finished product due to the fact that I haven't ...
[16 replies] Last: Thank you to everyone for their input. It is greatly appreciated. I am... (by OUIJ)
error: lvalue required as left operand of assignment
 
I get the following error: pointers_array.c: In function ‘readlines’: pointers_array.c:42:37: error: lvalue required as left operand of assignment ...
[3 replies] Last: Maybe I made a mistake somewhere. Hang on a sec. Let's try this again... (by long double main)
Delete function in C++
 
#include <iostream> #include <string> using namespace std; int main(void) { int *p1; p1 = new int; int *p2 = new int; int *p3; ...
[5 replies] Last: Delete does not necessarily clear memory, it de-allocates it. This ... (by Disch)
Balancing Statement in Red-Black tree, pointer problems
 
template <typename T> struct NODE { T data; NODE *left; NODE *right; string colour; int LHeight,RHeight; }; typedef NODE* ND; ND node; ND root...
[6 replies] Last: Line 27, you are using the assignment operator rather than the compari... (by Smac89)
programming
 
how to make statistics table in c++
[14 replies] Last: Post the code you have written so far. Make sure to put it [co de] be... (by LB)
January 2014 Pages: 1... 22232425
  Archived months: [dec2013] [feb2014]

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