General C++ Programming - December 2011 (Page 11)

by NDP286
Error in get function
 
I was trying to create my own vector class for basic operations push_back, pop_back and at. i was able to do pushback and popback successfully but not at functi...
[4 replies] Last: at() is the same like the operator , So: Temp at(int i); The body is... (by coder777)
char s* and char s[]
 
Code: #include <iostream> using namespace std; void main() { char *s="hello"; cout << &s << endl; cout << static_cast<void*>(s) << endl; cout <<...
[1 reply] : cs is an array so &cs gives you a pointer to the first element in the ... (by Peter87)
Not leaving the function
 
#include <iostream> #include <Windows.h> #include <string> using namespace std; int gameloop(); void gameload(); void descgetter(); void input(); ...
[5 replies] Last: It does work. It does exactly what you programmed it to do. We are no... (by Moschops)
How to define an identifier
 
This is my code #include <iostream> #include <string> using namespace std; string subject; string question; int main() { ask; close; } int...
[6 replies] Last: Thanks. It's working now. (by Adam Chance)
by anjaly
convert this c++ code to c
 
static void FarnebackUpdateFlow_GaussianBlur( const Mat& _R0, const Mat& _R1, Mat& _flow, Mat& matM, int block_size, ...
[1 reply] : [quote=anjaly]convert this c++ code to c I'll pass on that. Thank you... (by closed account 1vRz3TCk)
by poolet
Return a value
 
Well, I have create a calculator project and I have a little problem here.. I don't need a solution ( and I will not post my code, if you help to see my code pl...
[3 replies] Last: I am not sure you really need void * . Since you don't post any code ... (by eypros)
"If" statements are being ignored.
 
Alright, a couple explanations: 1. I account for the discrepancy between an array subscript and what I refer to as the "Room Number". In for for loop to define...
[2 replies] Last: Alrighty, I think I found the problem. I wasn't clearing out old data ... (by supersoup)
Is the temporary objects created by compiler is const?
 
In the following code snippet myclass testTemp() { return myclass(3,4); } in this, The myclass object created by compiler is a const?
[10 replies] Last: Why are you trying to return this: X f5() { return X(); } In this f... (by eypros)
by Phiru
what's difference btw ftp and http??
 
I am trying to make Uploader component, but there are two types(actually three) of it. FTP, HTTP(, and gopher). Howerver, I don't know what the difference be...
[4 replies] Last: this is important in html. an ftp is a way of sending files to your we... (by Aramil of Elixia)
Problem with SendInput function
 
Hello all. I'm trying to synthesize alt + space to bring up the output window's menu using SendInput(). For some reason it works on other windows that I click o...
[5 replies] Last: Woooooo it works thanks!! (by LsDefect)
Formatting a string error.
 
Why is it that when I call this function from any other, it gives me an out_of_range at memory location foo error? string format(string text) // Needs lots ...
[3 replies] Last: Thanks so much guys! Problem solved =) (by supersoup)
Array map...and hit detection...console
 
#include <iostream> using namespace std; void movePlayer(); void youWin(); const int COLS = 14; const int ROWS = 7; int map = { 1, 1, 1, 1, 1,...
[1 reply] : A problem well stated is a problem half solved. You haven't mentioned... (by Stewbond)
How can I minimize this code?
 
How can I minimize this code. My prof has told me to fix this but I dont know how to. The swap in the sorts can and should use object assignment so that you c...
[16 replies] Last: If you just overloaded the assignment operator for your objects you c... (by IceThatJaw)
Passing an object to a function?
 
Im having a problem passing a specif object of a class to a function. I am getting error codes left an right. Will someone be willing to help me. My code is bel...
[4 replies] Last: I also assumed that Juventus was the name of a class. In other words,... (by webJose)
How to make an application on a Desktop
 
I've been questioning this for a while now, and from what I understand, you do this: 1.) Release the binary files (or the source code, if you think that the ...
[9 replies] Last: what do you mean? I have a mac and (except for one exception which is ... (by Aramil of Elixia)
Can you improve this BNR packing function?
 
I have created the following function which seems to correctly pack BNR values (2's complement) of an unspecified type (float, double) into another unspecified ...
[5 replies] Last: I think in case of floating-point T you could drop all the complexity ... (by Cubbi)
Audio APIs
 
Hi All, I am looking for an Audio API and was wondering what everyone else uses or if they have any recommendations. My premise: I am writing a "radio chatte...
[5 replies] Last: PortAudio, perhaps? Requirement 1: Fulfilled, though I had some stabi... (by Albatross)
FINAL C++ 101 HELP PLZ!
 
I FIXED THIS MYSELF. HOW THE FUCK DO YOU DELETE THIS?
[4 replies] Last: OP says (now with code tags included!): The purpose of this lab is t... (by Moschops)
by eypros
Issues to take in mind when publishing posts
 
I decided to write a post for those posts that have a rather inappropriate format (and does not help to read them or comment them) Suggested format for posti...
[4 replies] Last: 8) Post the traceback of the error. It may appear to be gibberish t... (by cnoeval)
What's the easiest way to tell if a wchar_t is alphanumeric?
 
What's the easiest way to tell if a wchar_t is alphanumeric? unsigned int dwLength = wcslen( str ); for( unsigned int i = 0; i < dwLength; i++ ) { ...
[2 replies] Last: The suitable functions are std::iswalnum() from <cwtype> or std::... (by Cubbi)
December 2011 Pages: 1... 910111213... 39
  Archived months: [nov2011] [jan2012]

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