General C++ Programming - June 2013 (Page 19)

Problem on Reading/Writing a complex object from/to File
 
Hello everyone!..I have a problem with I/O as i try to read/write a complex object from/to a file,but it throws me segmentation fault during the execution of th...
[2 replies] Last: Yes of course!...But i'm also not sure about the way i handle the I/O ... (by chriszo)
by Niven
Rotating SDL_Surfaces
 
Since SDL doesn't have it's own function for rotating images and I'm tired of storing multiple angles of the same sprite in a file, I created my own function fo...
[3 replies] Last: Personally I wouldn't spend too much time looking into SDL_gfx and try... (by Hippogriff)
Offsetting Bezier Curve
 
Looking at Bezier curves has been pretty simple so far but I seem to have run into a slight problem. Right now I am trying to create a "railroad" type object fr...
[6 replies] Last: Assuming I have implemented your equations correctly I came up with th... (by Hippogriff)
char vector question
 
Hello, i just had question but did not understand the previous answers I want to save the char // fixed size 2 dimension array to a vector such as...
[4 replies] Last: When you do vector<vector<char> > temp; , it makes a 2d char vector. ... (by cire)
Subtracting values in a vector
 
I am just learning C++ and I want to add this piece of code to a project. I have created a vector from values entered by a user. I want to then subtract each va...
[5 replies] Last: You can do your task applying standard algorithm std::accumulate to an... (by vlad from moscow)
Expecting Stack overflow error?
 
Hi, After not programming for sometimes I decided to program a small application. But I have some trouble according to what I remember and re-checking arrays...
[1 reply] : Nope, that's simply undefined behaviour (by ne555)
Array List
 
This is an assignment question i will appreciate any kind of help. In C++, there is no check to determine whether the array index is out of bounds.Design a cla...
[1 reply] : In your assignment there is written very clear "Redesign the class my... (by vlad from moscow)
by JiLe
Binary file - menu of functions
 
First of all sorry for my bad English. I had to use dictionary to write this message. I can't figure out how to write a programme for maintaince of a binary fil...
[no replies]
SDL trouble with side collision detection
 
Hi, i'm working on a sidescroller game and for now Igot trouble with the collision form both right and left side. Top and bottom collision seems to work properl...
[no replies]
by swsw
Integer array to BMP
 
I have a problem concerning transforming int array into bmp image. I wanted to add a post in this topic: http://www.cplusplus.com/forum/beginner/12848/ , but u...
[2 replies] Last: Chances are you are trying to read memory not allocated to the array, ... (by Duthomhas)
If C is called God's programming language, then C++ is?
 
If there is no alias for C++, I think writers should start creating now and we will all appreciate it.
[1 reply] : Your premise is wrong. http://xkcd.com/224/ BTW, this belongs in the... (by Duthomhas)
Generating Random Integers
 
I know this has been asked here many times before, but anyway... I'm creating a game in C++ and need to generate random numbers. I know about int main(...
[3 replies] Last: #include <cstdlib> #include <ctime> #include <random> #include <itera... (by JLBorges)
by rjizzo
Counter issues
 
Can someone explain to me what I am doing wrong in regards to the "EmployeeCounter" in the (Main) section of the code? It compiles and runs, but when you enter ...
[1 reply] : In your while loop, you're not incrementing the EmployeeCount variable... (by crimsonzero2)
by htroyo
c++ gui framework for commercial software
 
Hello, i'n new at this forum so sorry if it is not a good question fod this forum. I'm looking for a good gui framework for commercial software development, i ...
[4 replies] Last: I'm configuring wxwidgets in order to start testing, but i have a ques... (by htroyo)
readjusting code so the function works.
 
#include <iostream> #include <string> #include <cmath> using namespace std; int year1; int year2; int year3; int month1; int month2; int month3; int day1; int ...
[2 replies] Last: Thanks. (by hello234)
Reading source code from uncompleted files
 
I know it sounds strange but I've seen things that have files which contain source code (usually in something in Python or such) and I was wondering how this is...
[1 reply] : What do you think your compiler does? The only difference is that your... (by LB)
Code blocks crashes when I try to run
 
This has happend before, when I try to run a code it will say "blah.exe has stopped working" and I would have to change the code in some way to make it work. Do...
[1 reply] : Fix what? You didn't show any code. There can be many reasons for... (by AbstractionAnon)
Casting a logical boolean as an int? (1,2)
 
I have never run across a situation just like this one below and thought I would ask your thoughts on it. Let's say I have a product that needs service after...
[21 replies] Last: OK. lets not continue this discussion, because it looks like we cannot... (by MiiNiPaa)
May I ask you a bit stupid question?
 
Hello. Recently, I was looking through the source code of the app written in India(Bangalore) and I found those lines of code: private: #define TIME_OUT ...
[6 replies] Last: Apparently not just open source code... From xstring provided with Vi... (by andywestken)
code::blocks no longer giving any useful errors
 
I'm using Code:Blocks 12.11 on windows 7, with the built-in MinGW compiler. When I try and compile a program that has an error in it (misnamed variable, missin...
[11 replies] Last: Bump (by JLBorges)
June 2013 Pages: 1... 1718192021... 28
  Archived months: [may2013] [jul2013]

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