Click here to Skip to main content
16,020,811 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: How to make truncation in C++ Pin
Rajesh R Subramanian2-Jul-09 22:16
professionalRajesh R Subramanian2-Jul-09 22:16 
AnswerRe: How to make truncation in C++ Pin
Stuart Dootson2-Jul-09 22:16
professionalStuart Dootson2-Jul-09 22:16 
AnswerRe: How to make truncation in C++ Pin
Michael Schubert2-Jul-09 22:19
Michael Schubert2-Jul-09 22:19 
GeneralRe: How to make truncation in C++ Pin
CPallini2-Jul-09 22:36
mveCPallini2-Jul-09 22:36 
GeneralRe: How to make truncation in C++ Pin
Rajesh R Subramanian2-Jul-09 22:50
professionalRajesh R Subramanian2-Jul-09 22:50 
GeneralRe: How to make truncation in C++ Pin
CPallini2-Jul-09 22:56
mveCPallini2-Jul-09 22:56 
AnswerRe: How to make truncation in C++ Pin
KarstenK3-Jul-09 3:21
mveKarstenK3-Jul-09 3:21 
AnswerRe: How to make truncation in C++ Pin
Dan3-Jul-09 10:21
Dan3-Jul-09 10:21 
The FPU already does this for you.

   //! Round double to integer
inline int iround(double v){
    int retval;
    __asm fld qword ptr [v]
    __asm fistp dword ptr [retval]
    return retval;

}

//! Round double to unsigned integer
inline unsigned int uround(double v){
    unsigned retval;
    __asm fld qword ptr [v]
    __asm fistp dword ptr [retval]
    return retval;
}

GeneralRe: How to make truncation in C++ Pin
Michael Schubert3-Jul-09 12:19
Michael Schubert3-Jul-09 12:19 
QuestionHow to make a LONGLONG array ? Pin
krish_kumar2-Jul-09 21:25
krish_kumar2-Jul-09 21:25 
AnswerRe: How to make a LONGLONG array ? Pin
«_Superman_»2-Jul-09 21:30
professional«_Superman_»2-Jul-09 21:30 
GeneralRe: How to make a LONGLONG array ? Pin
krish_kumar2-Jul-09 21:50
krish_kumar2-Jul-09 21:50 
QuestionGetPrivateProfileString() problem Pin
ashish8patil2-Jul-09 20:22
ashish8patil2-Jul-09 20:22 
AnswerRe: GetPrivateProfileString() problem Pin
«_Superman_»2-Jul-09 20:34
professional«_Superman_»2-Jul-09 20:34 
GeneralRe: GetPrivateProfileString() problem Pin
ashish8patil2-Jul-09 21:31
ashish8patil2-Jul-09 21:31 
QuestionSTL find errors Pin
thelonesquirrely2-Jul-09 13:34
thelonesquirrely2-Jul-09 13:34 
AnswerRe: STL find errors Pin
«_Superman_»2-Jul-09 16:49
professional«_Superman_»2-Jul-09 16:49 
GeneralRe: STL find errors Pin
CPallini2-Jul-09 20:48
mveCPallini2-Jul-09 20:48 
GeneralRe: STL find errors Pin
«_Superman_»2-Jul-09 21:35
professional«_Superman_»2-Jul-09 21:35 
QuestionQuestion about some code that should crash but does not (release vs. debug & VS2003 vs. VS2008) Pin
Maximilien2-Jul-09 9:23
Maximilien2-Jul-09 9:23 
AnswerRe: Question about some code that should crash but does not (release vs. debug & VS2003 vs. VS2008) Pin
Stuart Dootson2-Jul-09 10:32
professionalStuart Dootson2-Jul-09 10:32 
GeneralRe: Question about some code that should crash but does not (release vs. debug & VS2003 vs. VS2008) Pin
Maximilien2-Jul-09 12:57
Maximilien2-Jul-09 12:57 
AnswerRe: Question about some code that should crash but does not (release vs. debug & VS2003 vs. VS2008) Pin
Christopher W. Smith2-Jul-09 20:39
Christopher W. Smith2-Jul-09 20:39 
GeneralRe: Question about some code that should crash but does not (release vs. debug & VS2003 vs. VS2008) Pin
Maximilien3-Jul-09 1:04
Maximilien3-Jul-09 1:04 
Questionhow can i get file names dynamically? Pin
santhosh-padamatinti2-Jul-09 8:50
santhosh-padamatinti2-Jul-09 8:50 

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.