A simple solution: use a cast I=(int)D;
Be warned: you'll loose precision, a lot of, so you must be aware of what
you're doing.
But.. what do you mean with "add to a vector". Vectors can be made of
everything.

Mik of ClassX
--



----- Original Message -----
From: "theresa gartland-jones" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, April 23, 2004 12:06 PM
Subject: [JAVA2D] FW: Double to int


> How do I convert a double to an int, so I can add it to a vector?
>
> Thanks.
>
>
===========================================================================
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the
body
> of the message "signoff JAVA2D-INTEREST".  For general help, send email to
> [EMAIL PROTECTED] and include in the body of the message "help".
>

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA2D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to