49,766 Topics

Member Avatar for
Member Avatar for sasho648

I want to make a mouse controlled camera the problem is that i want to rotate over the space not the current object but I don't know how to calculate the changes on view transformation. Here is the code example: [CODE] D3DXMatrixLookAtLH(&matView, &D3DXVECTOR3 (0.0f, 0.0f, CurCamRot.z), // the camera position …

0
316
Member Avatar for MrEARTHSHAcKER

Hi, I have an app created in Borland Builder 6, on Win 7, but I tested it on Win XP, and font's size changed, some forms resized... This guy has explained the problem >> [url]http://www.tek-tips.com/viewthread.cfm?qid=1668509[/url] Anyone experienced with this?

0
45
Member Avatar for bobanderson93

something is wrong with my dequeue function. When i try to output the value that's about to get deleted i get garbage on the console window. the enqueue function works fine. [CODE]class Queue { private: int value; Queue *next; public: void dequeue(); void enqueue (int num); }; Queue *head=NULL; void …

Member Avatar for Karkalash
0
178
Member Avatar for vyrte

hello everyone! i'm writing a program using linux environment and i'm curious about the use of waitpid().i have searched the command on google but i'm not sure i understood the return values of the command. for example i want to use it as follows: [CODE]if(waitpid(-1,&status,WNOHANG )>0) sum++; [/CODE] where sum …

Member Avatar for Ancient Dragon
0
127
Member Avatar for Irina77

I am trying to build a console project using Microsoft Visual C++ 2008 Express. I included a static third-party library (no source code available) by adding the name to the Additional Dependencies (in Project Properties\Linker\Input). Additionally, I added the path of the folder where the ThirdPartyLib.lib is to the Tools\ProjectsAndSolutions\Directories …

Member Avatar for Irina77
0
613
Member Avatar for Al Borland

Hi all just wanted to take a moment to introduce myself. I stumbled upon these forums while looking up more information on programming in C++. It looked very useful and it would be nice to have a forum I can ask questions on and post problems I"m having with coding. …

Member Avatar for PrimePackster
0
187
Member Avatar for stereomatching

I am trying to write some simple programs related to network and I boost::asio as a tool to start with Below is one of the example from a blog(I alter it a little bit) [code] void OnConnect(const boost::system::error_code & ec) {} void asio_7b() { asio::io_service io_service; asio::ip::tcp::socket sock(std::ref(io_service) ); try …

Member Avatar for stereomatching
0
158
Member Avatar for rohan121212

Hey everyone out there please help me with this code [code] #include<iostream> #include<stdlib.h> #include<time.h> using namespace std; int main() { long n; cout<<"Enter no. of random numbers to be generated\n"; cin>>n; int arr1[n]; srand(time(NULL)); for(int i=0;i<n;i++) { arr1[i]=rand(); } int x=0; int pos=0; double k=time(NULL); for(int i=0;i<n-1;i++) { x=arr1[i]; for(int …

Member Avatar for LRRR
0
141
Member Avatar for sathya88

i need some help..for vc++ 6.0 like vb inputbox...is there any inputbox available for dialog or sdi based mfc application... in vc++ is there any page navigation is possible... like vb hide or invisible...

0
56
Member Avatar for sathya88

am want to develop a file transfer program in vc++.. normal text file it is possible.. but is it can read for multimedia file.... like java here byte read is possible...

Member Avatar for sathya88
0
153
Member Avatar for cangan

Hii, I had an application which suffers from crazy scrollbars. When textboxes are loaded with some array elements their scrollbars scrolls towards to the bottom of the boxxes.So the multiline textboxes looks as if they are empty !!! However, when i open an empty project to see if this situation …

0
111
Member Avatar for dedmon

I kind of lost here... I have the book but it does not show the loop... I want to use je 100 but this is not the same language Using the IAS computer instruction set to write a program for the following C(I)=A(I) + B(I) for I = 1,2,... 100 …

0
87
Member Avatar for lmytilin

I'm a little lost with C++ so I could really use your help with this one! I googled it but nothing does what I want to do! So here is my problem... Let's say I have a file like this: A 10 20 30 40 B 25 13 100 99 …

Member Avatar for Lerner
0
179
Member Avatar for bobanderson93

every time i run the program it prints out 0. I think something is wrong with my display function but i cant see the problem. [CODE]#include <iostream> using namespace std; #define STACKSIZE 10 class stack { private: int arr[STACKSIZE+1]; int tos; public: stack(); void push(int x); int pop(); bool is_empty(); …

Member Avatar for richieking
0
135
Member Avatar for jonnyboy12

Hello all. I am trying to figure our how to add a pin and unpin button on one of my ms visual forms. An example of this is the pin that in used on the top right of the solution explorer in ms visual. I know that in the basic …

0
59
Member Avatar for Smartflight

We have been assigned to make a program for a bank using data file handling, as our project. I am having some trouble at this point... the last object written in the file is printed twice and I've no clue as to why. Case for display: [CODE]file.open("Records.dat", ios::in | ios::binary); …

Member Avatar for WaltP
0
558
Member Avatar for triumphost

Sorry for using Inception in the title but it's the only way I think I can describe it.. Take this for example: Definition.H [CODE] struct XY { string info; string name; string tag; string attrib; }; //is it better to create an object here inorder to make the array? struct …

Member Avatar for triumphost
0
141
Member Avatar for vyrte

hello everyone! i'd like to know if theres a way to run my program until the user presses Esc button. i use linux environment and my main function runs fork().i want the program to stop the fork() when the user presses escape. thank you!

Member Avatar for WaltP
0
178
Member Avatar for jigglymig

I am trying to make a circular linked list and I think I am not linking it properly in the middle area because I can print the last and first node, but not the rest... [CODE]#include <iostream> #include <new> using namespace std; struct node { int Item; node* Next; }; …

Member Avatar for Lerner
0
107
Member Avatar for PainOfTruth

Please help me run this program, i forgot the output of this.. [CODE] #include<iostream> #include<cmath> using namespace std; class SumTwoNumbers { int nx,ny,sum,suma,sumtn; public: int GetFirstNumber(); int GetSecondNumber(); int GetSum(int,int); void Display(int,int); }stn; int SumTwoNumbers::GetFirstNumber() sum=nx+ny; //here is where the errors i wrote below points! i dont know why return(sum); …

Member Avatar for sharathg.satya
0
414
Member Avatar for Ayzu

I'm trying to implement priority queue using a singly linked list, but the program is not running in the best way, n the display function is showing just first n last node's data , y??? [CODE]#include<iostream.h> #include<conio.h> struct node { int n,p,b; // Data members for getting Task no. ,Priority …

Member Avatar for Ayzu
0
244
Member Avatar for venky019

Hi, I got this error while trying to access the method that I've posted here. Main program: cin>>sname; string x; Sports x = Sports.getName();//error:a nonstatic member reference must be relative to a specific object. loc=x.find(sname); In Sports.cpp: string Sports::getName() {return name;} I've declared getName() function as public.Still I'm getting this …

Member Avatar for Ancient Dragon
0
3K
Member Avatar for ichigo_cool

Hey everyone, I've made a game with SDL and I'm now trying to distribute it. I've included all of the required .DLLs and such but now I get this error whenever I try to run the .exe: The application or DLL E:\GAME\DEBUG\MSVCR100.dll is not a valid Windows image. please check …

Member Avatar for Tumlee
0
459
Member Avatar for jdm

I'm writing a dayType class program and I'm having trouble with comparing two different days to each other. Here is what I have for them: bool dayType::equalDay(const dayType& otherday) const { } and here is main: if (day.equalDay(newday)) cout << " equal days" << endl; else cout << "not equal …

Member Avatar for jdm
0
96
Member Avatar for LucyButterfly22

Hey guys, I'm fairly new to C++ and I was wondering if I could get a hand with something. I'm trying to write a program that will create something called an anti-saccade task, in which the subject of the experiment would have to look away from the stimulus, for my …

Member Avatar for DeanMSands3
0
108
Member Avatar for sync101

Hi there, I am new to C++, and was wondering if someone could write an example program for me to work with. What I would like to do is take input from stdin and then display the translate output to stdout. Example: Input: [code] (color 0 0 0.1) // These …

Member Avatar for jaskij
0
106
Member Avatar for stereomatching

[code] struct String { String() { std::cout<<"String::String(), this="<<this<<std::endl; } ~String() { std::cout<<"String::~String(), this="<<this<<std::endl; } String(String const &other) { std::cout<<"String::String(String const &other), this="<<this; std::cout<<", other="<<&other<<std::endl; } String& operator=(String const &other) { std::cout<<"String::operator=(String const &other), this="<<this; std::cout<<", other="<<&other<<std::endl; return *this; } }; String const operator*(String const &lhs, String const &rhs) { String …

Member Avatar for stereomatching
0
176
Member Avatar for CrewAlien
Member Avatar for Smartflight
0
302
Member Avatar for Lensva

Code works, however i'm having problems with reverse string- i cant figure out how to index the elements. for cycle returns errors, what else could i use? The end goal would be to compare string line with string reverse. If adequate elements match its a palindrome. [code=c++] #include <iostream> #include …

Member Avatar for rohitvipin
0
2K
Member Avatar for cl2020

I have a palindrome set up in the system, and running fine. However, when I type "never odd or even" or "A Man, A Plan, A Canal, Panama", it didn't run properly as if these words in quotation marks are considered palindromes. Where is the loophole on my code re: …

Member Avatar for youjean
0
336

The End.