.\" -*- nroff -*- .\" Generated file - DO NOT EDIT! .TH VarI8FromR8 3w "Oct 2012" "Wine API" "Wine API" .SH NAME \fBVarI8FromR8\fR (OLEAUT32.336) .SH SYNOPSIS HRESULT VarI8FromR8 ( double \fIdblIn\fR, LONG64* \fIpi64Out\fR ) .SH DESCRIPTION .PP Convert a \fBVT_R8\fR to a \fBVT_I8\fR. .SH PARAMS \fIdblIn\fR \fB[In]\fR Source. .PP \fIpi64Out\fR \fB[Out]\fR Destination. .PP .SH RETURNS .PP \fBSuccess:\fR \fBS_OK\fR. .PP \fBFailure:\fR \fBE_INVALIDARG\fR, if the source value is invalid \fBDISP_E_OVERFLOW\fR, if the value will not fit in the destination. .SH NOTES .PP Only values that fit into \fB63\fR bits are accepted. Due to rounding issues, very high or low values will not be accurately converted. .PP Numbers are rounded using Dutch rounding, as follows: .br Fractional Part Sign Direction Example .br --------------- ---- --------- ------- .br < 0.5 + Down 0.4 -> 0.0 .br < 0.5 - Up -0.4 -> 0.0 .br > 0.5 + Up 0.6 -> 1.0 .br < 0.5 - Up -0.6 -> -1.0 .br = 0.5 + Up/Down Down if even, Up if odd .br = 0.5 - Up/Down Up if even, Down if odd. .PP This system is often used in supermarkets. .SH IMPLEMENTATION .PP Declared in \fB"oleauto.h"\fR. .PP Implemented in \fB"dlls/oleaut32/vartype.c"\fR. .PP Debug channel \fB"variant"\fR.