In Java 3D 1.2, the only way to modify the texture is by creating a new
ImageComponent2D object, as you describe. It is not legal to modify
the BufferedImage directly. In Java 3D 1.3, we are adding updateData
methods to ImageComponent{2D,3D} and a new ImageComponentUpdater object
that will allow you to modify all or part of a BufferedImage in place.
--
Kevin Rushforth
Java 3D Team
Sun Microsystems
[EMAIL PROTECTED]
>Date: Mon, 4 Jun 2001 18:55:08 -0700
>From: Donnie Pinkston <[EMAIL PROTECTED]>
>Subject: [JAVA3D] dynamically-updated textures
>To: [EMAIL PROTECTED]
>
>I am wondering if the following is possible:
>
>I would like to have a BufferedImage object that is used by a by-reference
>ImageComponent2D object, which is then part of a Texture2D that is used as
>an object's appearance. How can I get changes to the contents of the
>BufferedImage to actually show up in the rendered scene?
>
>So far, the only way I can get changes in the BufferedImage to show up is to
>hand the Texture2D a new ImageComponent2D object that is by-copy, every time
>the BufferedImage changes. This is very costly in terms of memory use!!!
>
>I have tried to get the by-reference ImageComponent2D to work, but changes
>to the image referenced by the ImageComponent2D don't show up in the scene.
>How can I get this to work?
>
>I know that there has to be a smart way to do this, but I cannot seem to
>find it yet. Any help would be greatly appreciated.
>
>-Donnie Pinkston
>
>===========================================================================
>To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
>of the message "signoff JAVA3D-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 JAVA3D-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".