Click here to Skip to main content
16,004,828 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionWriting 64-bit code with VS 2005 Standard ? Pin
Defenestration28-Mar-06 4:19
Defenestration28-Mar-06 4:19 
AnswerRe: Writing 64-bit code with VS 2005 Standard ? Pin
Defenestration28-Mar-06 4:30
Defenestration28-Mar-06 4:30 
GeneralClicket police! Pin
Trollslayer28-Mar-06 7:26
mentorTrollslayer28-Mar-06 7:26 
QuestionProfiling code in VC++ 2005 ? Pin
Defenestration28-Mar-06 4:16
Defenestration28-Mar-06 4:16 
QuestionHow to pass array as a reference parameter? Pin
Ming Luo28-Mar-06 3:18
Ming Luo28-Mar-06 3:18 
AnswerRe: How to pass array as a reference parameter? Pin
toxcct28-Mar-06 3:37
toxcct28-Mar-06 3:37 
AnswerRe: How to pass array as a reference parameter? Pin
BadKarma28-Mar-06 3:53
BadKarma28-Mar-06 3:53 
AnswerRe: How to pass array as a reference parameter? Pin
khan++28-Mar-06 3:57
khan++28-Mar-06 3:57 
In addition to the above suggestion of using vectors etc, you could also use the old methods. Note that I haven't tested it.

//Also make sure that the src parameter is now large enough.
void ScaleVector(float *src, float deltaT)
{
for (int i = 0; i < p.n; i++)
{
float vx = src[i]; // velocity on x axis
float vy = src[i+1]; // y axis
float vz = src[i+2]; // z axis
float ax = src[i+3]; // acceleration on x axis
float ay = src[i+4]; // y axis
float az = src[i+5]; // z axis
src[i] = vx * deltaT + 0.5 * ax * deltaT * deltaT; // calculate the displacement at x axis
src[i+1] = vy * deltaT + 0.5 * ay * deltaT * deltaT; // y axis
src[i+2] = vz * deltaT + 0.5 * az * deltaT * deltaT; // z axis
src[i+3] = ax * deltaT; // added speed at x
src[i+4] = ay * deltaT; // y
src[i+5] = az * deltaT; // z
}
}


this is this.
QuestionCreateProcess Pin
ilgale28-Mar-06 3:12
ilgale28-Mar-06 3:12 
AnswerRe: CreateProcess Pin
Hamid_RT28-Mar-06 3:20
Hamid_RT28-Mar-06 3:20 
GeneralRe: CreateProcess Pin
ilgale28-Mar-06 3:25
ilgale28-Mar-06 3:25 
GeneralRe: CreateProcess Pin
Rage28-Mar-06 3:39
professionalRage28-Mar-06 3:39 
GeneralRe: CreateProcess Pin
ilgale28-Mar-06 3:48
ilgale28-Mar-06 3:48 
GeneralRe: CreateProcess Pin
Rage28-Mar-06 3:59
professionalRage28-Mar-06 3:59 
GeneralRe: CreateProcess Pin
ilgale28-Mar-06 4:06
ilgale28-Mar-06 4:06 
GeneralRe: CreateProcess Pin
khan++28-Mar-06 4:12
khan++28-Mar-06 4:12 
GeneralRe: CreateProcess Pin
ilgale28-Mar-06 4:15
ilgale28-Mar-06 4:15 
GeneralRe: CreateProcess Pin
khan++28-Mar-06 4:26
khan++28-Mar-06 4:26 
QuestionMessage encryption and splitting Pin
cjsin28-Mar-06 2:05
cjsin28-Mar-06 2:05 
AnswerRe: Message encryption and splitting Pin
Rage28-Mar-06 4:06
professionalRage28-Mar-06 4:06 
Questionvmr9.h Pin
William Burton28-Mar-06 1:16
William Burton28-Mar-06 1:16 
AnswerRe: vmr9.h Pin
Saurabh.Garg28-Mar-06 1:33
Saurabh.Garg28-Mar-06 1:33 
QuestionTo make DateTimePicker Appear flat Pin
mikobi28-Mar-06 1:08
mikobi28-Mar-06 1:08 
QuestionBitmap size: LP or DP? Pin
includeh1028-Mar-06 0:51
includeh1028-Mar-06 0:51 
QuestionCListCtrl SetItem Pin
Naveen28-Mar-06 0:48
Naveen28-Mar-06 0:48 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.