[JAVA3D-675] j3d-1_5_2-windows-amd64.exe does not install the files into JRE folder Created: 19/Jun/12  Updated: 19/Jun/12

Status: Open
Project: java3d
Component/s: None
Affects Version/s: 1.5.2
Fix Version/s: None

Type: Bug Priority: Blocker
Reporter: darwinjob Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Windows Enterprise 7 64 bit, java version "1.7.0_05"
Java(TM) SE Runtime Environment (build 1.7.0_05-b05)
Java HotSpot(TM) 64-Bit Server VM (build 23.1-b03, mixed mode)



 Description   

If I run the installer j3d-1_5_2-windows-amd64.exe it installs the files into C:\Program Files\Java\Java3D only, not into C:\Program Files\Java\jre7 where I have my default and only Java installation. So, when I run my Java3D application "it says "No Java3D installed" (obviously).






[JAVA3D-672] AWT/ GUI Issues on Core i5/ Intel HD Graphics Workstations Created: 20/Jan/12  Updated: 26/Mar/12

Status: Open
Project: java3d
Component/s: None
Affects Version/s: 1.5.1
Fix Version/s: None

Type: Bug Priority: Major
Reporter: tomzwicker Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Windows 7, Intel Core i5 Processors 2430/ 2467, Intel HD 3000 and Radeon HD6630M (Samsung Slate PC 700T and Dell Vostro 3350)
Java 6 and Java 7


Attachments: JPEG File IMAG0212.jpg    

 Description   

While Java3D and AWT works fine on older hardware, the newest workstations show flickering and distorted AWT components.

Java3D canvas shows OK. However, after editing e.g. AWT combobox in a neighbouring panel the AWT components are no longer displayed correctly. They show partially distorted, partially normal with strong flickering on every action/ update in the Java3D canvas. Other windows (non-Java applications like start-menu and web-browser) also get distorted and flicker.

It is not possible to work with the Java3D application for a user due to these effects.

Screenshots do not show the distortions.

The error occurs on Java 7 and Java 6.



 Comments   
Comment by tomzwicker [ 26/Mar/12 ]

Screen-photo (not a screenshot, as the screen shot does NOT show the distortions) of the windows environment running office in the background and the Java3D app in the foreground.

Distortions are seen left of the Java/ Java3D window in the office-background. Farther distortions are shown in the lower left-hand corner of the windows screen.

Notice that all areas of the screen, also the Java3D window, get distorted.

Taking a screenshot did not store the distortion to the file. So it may be well possible a driver issue in windows.

Comment by tomzwicker [ 26/Mar/12 ]

Tried Java 32 bit/ 64 bit, Java Version 6 and 7 (latest), Java3D 1.5.1 and 1.5.2 on Windows 7 - all caused the same issue





[JAVA3D-671] Multiple clip Created: 11/Nov/11  Updated: 11/Nov/11

Status: Open
Project: java3d
Component/s: None
Affects Version/s: 1.6.0
Fix Version/s: None

Type: New Feature Priority: Major
Reporter: mejlango Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

Multiple clip of model could be allowed. Group with child groups (or shapes) then could allow clip each child using child's own clip and also clip itself and all childs using its clip.






[JAVA3D-668] LineAttributes setting line width Created: 10/Oct/11  Updated: 10/Oct/11

Status: Open
Project: java3d
Component/s: None
Affects Version/s: 1.5.2
Fix Version/s: None

Type: Bug Priority: Major
Reporter: mejlango Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

linux x64, debian 5 (sun java 1.6.27)



 Description   

Setting the line width > 10 sets the line width to 10 on NVIDIA (but works correctly on ATI) (I tried it with custom patterned line style)
Documentation does not say anything about restriction of line width.






[JAVA3D-669] Antialiasing causes fatal error Created: 10/Oct/11  Updated: 10/Oct/11

Status: Open
Project: java3d
Component/s: None
Affects Version/s: 1.5.2
Fix Version/s: None

Type: Bug Priority: Major
Reporter: mejlango Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

linux x86 - debian 5, Windows 7 x64 (sun java 1.6.27)



 Description   

jvm crash randomly occurs when implicit antialiasing is set to true, or line's LineAttributes has antialiasing set to true. Works fine on NVIDIA, but not on mobility ATI HD 4500/5100 or ATI HD 3200






[JAVA3D-673] AWT/ GUI Issues with Windows 7 on Core i5/ Intel HD Graphics Workstations Created: 13/Feb/12  Updated: 13/Feb/12

Status: Open
Project: java3d
Component/s: None
Affects Version/s: 1.5.1
Fix Version/s: None

Type: Bug Priority: Major
Reporter: tomzwicker Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Windows 7, Intel Core i5 Processors 2430/ 2467, Intel HD 3000 and Radeon HD6630M (Samsung Slate PC 700T and Dell Vostro 3350)
Java 6 and Java 7



 Description   

While Java3D and AWT works fine on older hardware, the newest workstations show flickering and distorted AWT components.

Java3D canvas shows OK. However, after editing e.g. AWT combobox in a neighbouring panel the AWT components are no longer displayed correctly. They show partially distorted, partially normal with strong flickering on every action/ update in the Java3D canvas. Other windows (non-Java applications like start-menu and web-browser) also get distorted and flicker.

It is not possible to work with the Java3D application for a user due to these effects.

Screenshots do not show the distortions.

The error occurs on Java 7 and Java 6.






[JAVA3D-674] Offscreen rendering is missing geometry/content branch (sometimes) Created: 04/Apr/12  Updated: 10/Oct/12

Status: Open
Project: java3d
Component/s: j3d-core
Affects Version/s: 1.5.2
Fix Version/s: None

Type: Bug Priority: Major
Reporter: sstevenson638 Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Windows XP, NVIDIA graphics card



 Description   

When I do a screen capture using an offscreen canvas, the View does not always render the content branch of my scene graph. It seems to work when I run from Netbeans in debug mode and am breaking to look at code, but it almost never works when I run in non-debug mode.

The onscreen canvas always draws correctly. The offscreen canvas always draws the background correctly, but not the other content in the scene.

I use the same offscreen canvas component used in two different applications. One application uses a SimpleUniverse, the other I create my own Universe and View objects manually. The one using SimpleUniverse seems to capture images correctly, the one I created manually does not. Is there something about the View created by SimpleUniverse that could effect the behavior? I've looked all over the source to see if it does anything special, but haven't found anything.

Source to some of my components is listed below. The idea is to print Components that contain Java3D scenes using the normal Component.print() methods. They also support "Actors" that can draw on the Canvas3D after rendering is complete.

Please help! I've been working on this for a week and have no idea what is wrong. It's almost like a threading issue, but I think that I'm following all the rules.

class OffScreenCanvas3D extends MarkupCanvas3D {
private static Logger logger = Logger.getLogger(OffScreenCanvas3D.class);

volatile boolean waitingForRender = false;
int maxWaitTimeForRender = 3000;

/**

  • @param gc
    */
    public OffScreenCanvas3D(GraphicsConfiguration gc, int maxWaitTimeForReder) { super(gc,true); this.maxWaitTimeForRender = maxWaitTimeForRender; }

@Override
public void preRender()

{ super.preRender(); }

@Override
public void postRender()

{ super.postRender(); }

@Override
public void postSwap()

{ super.postSwap(); waitingForRender = false; }

public void renderOffScreenBufferAndWait() {
waitingForRender = true;

View view = this.getView();
view.repaint();
// Tell Java3D to render this canvas
if(!view.isViewRunning())

{ view.renderOnce(); }

else

{ super.renderOffScreenBuffer(); }

// Wait for rendering to finish.
// The Canvas3D.waitForOffScreenRendering does not seem to work and can cause thread deadlocks.
// It never re-sets is rendering flag while waiting.
int count = 0;
while(waitingForRender) {
try

{ Thread.sleep(2); }

catch (InterruptedException ex)

{ break; }

count+=2;
if(count>this.maxWaitTimeForRender)

{ logger.error("Failed to print 3D image. Rendering seems to be taking a long time."); break; // Give up and return if still have not rendered }

}
}

}

public class PrintableCanvas3DContainer extends Container {

private static Logger logger = Logger.getLogger(PrintableCanvas3DContainer.class);
private MarkupCanvas3D onScreenCanvas;
private OffScreenCanvas3D offScreenCanvas;
BufferedImage offScreenImageBuffer = null;
private transient List<Java2DActor> actors = new ArrayList();

/**

  • Creates a PrintableCanvas3DContainer with specified GraphicsConfiguration.
    *
  • @param gc
    */
    public PrintableCanvas3DContainer(GraphicsConfiguration gc) { super(); super.setLayout(new BorderLayout()); onScreenCanvas = new MarkupCanvas3D(gc, false); super.add(onScreenCanvas, BorderLayout.CENTER); }

/**

  • Creates a PrintableCanvas3DContainer with default GraphicsConfiguration obtained
  • from SimpleUniverse.getPreferredConfiguration().
    *
    */
    public PrintableCanvas3DContainer() { this(SimpleUniverse.getPreferredConfiguration()); }

/**

  • Returns the on-screen canvas displayed in this container.
  • This canvas is owned by this container and should never be added to an outside
  • component. Add this container to your containers instead.
  • @return
    */
    public final Canvas3D getOnScreenCanvas() { return this.onScreenCanvas; }

/**

  • Override all add and remove methods to prevent them.
  • @param comp
  • @return
    */
    @Override
    public Component add(Component comp) { throw new UnsupportedOperationException("PrintableCanvas3DContainer hardwired to contain only 1 Canvas3D object."); }

    @Override
    public Component add(String name, Component comp) { throw new UnsupportedOperationException("PrintableCanvas3DContainer hardwired to contain only 1 Canvas3D object."); }

@Override
public Component add(Component comp, int index)

{ throw new UnsupportedOperationException("PrintableCanvas3DContainer hardwired to contain only 1 Canvas3D object."); }

@Override
public void add(Component comp, Object constraints) { throw new UnsupportedOperationException("PrintableCanvas3DContainer hardwired to contain only 1 Canvas3D object."); }

@Override
public void add(Component comp, Object constraints, int index)

{ throw new UnsupportedOperationException("PrintableCanvas3DContainer hardwired to contain only 1 Canvas3D object."); }

@Override
public void setLayout(LayoutManager mgr)

{ throw new UnsupportedOperationException("PrintableCanvas3DContainer has hardwired LayoutManager."); }

/**

  • Print this component to make image captures.
    *
  • @param g
    */
    @Override
    public void print(Graphics g) {

View view = this.onScreenCanvas.getView();
if (view == null)

{ return; }

BufferedImage img = captureImageInternal();
if (img != null) { g.drawImage(img, 0, 0, null); }

}

@Override
public void printAll(Graphics g) { print(g); }

/**
* Capture the current display image.
*
* @return
*/
public BufferedImage captureImage() { BufferedImage image = captureImageInternal(); return image; // TODO make a copy of the image to return }

private BufferedImage captureImageInternal() { this.attachOffScreenCanvas(); View view = this.onScreenCanvas.getView(); Rectangle rect = this.onScreenCanvas.getBounds(); this.offScreenCanvas.setBounds(rect); Screen3D offScreenScreen = offScreenCanvas.getScreen3D(); Screen3D onScreenScreen = onScreenCanvas.getScreen3D(); offScreenScreen.setPhysicalScreenHeight(onScreenScreen.getPhysicalScreenHeight()); offScreenScreen.setPhysicalScreenWidth(onScreenScreen.getPhysicalScreenWidth()); offScreenScreen.setSize(onScreenScreen.getSize()); Point loc = onScreenCanvas.getLocationOnScreen(); offScreenCanvas.setOffScreenLocation(loc); offScreenCanvas.invalidate(); offScreenCanvas.renderOffScreenBufferAndWait(); BufferedImage img2 = offScreenCanvas.getOffScreenBuffer().getImage(); // offScreenCanvas.setOffScreenBuffer(null); // Must free off screen canvas ID for next use. return img2; }

public void attachOffScreenCanvas() {
if (offScreenCanvas != null) {
// Create a new off screen canvas if the size has changed.
if (!offScreenCanvas.getSize().equals(onScreenCanvas.getSize())) { // Re-size only seems to work for the 3D part, but the actors // don't render correctly in the first screen shot. // Must create a whole new offscreen canvas to get this to work when the window size changes. resizeImageBufferIfNeeded(); return; // this.detachOffScreenCanvas(); }
else {
// Size not changed so we can re-use the existing offscreen canvas.
// However,
// Detach and re-attach current offscreen canvas for each snapshot.
// This is the only thing that seems to fix the blank image issue that
// occures if this component is not visible or active.
// This step is not needed if the current component is always visible and active on the screen.
View view = this.onScreenCanvas.getView();
if (view == null) { return; }
boolean started = view.isViewRunning();
if (started) { view.stopView(); }
view.removeCanvas3D(offScreenCanvas);
view.addCanvas3D(offScreenCanvas);
if (started) { view.startView(); }
return; // no need to re-create the offscreen canvas
}
}
// If offscreen canvas is null, create, size, and attach the offscreen canvas
// offScreenCanvas = new OffScreenCanvas3D(this.onScreenCanvas.getGraphicsConfiguration(), 3000);
GraphicsConfiguration gconfig = SimpleUniverse.getPreferredConfiguration();
offScreenCanvas = new OffScreenCanvas3D(gconfig, 3000);
resizeImageBufferIfNeeded();
offScreenCanvas.setBounds(onScreenCanvas.getBounds());
for (Java2DActor java2DActor : actors) { offScreenCanvas.addActor((Java2DActor) java2DActor.clone()); }
View view = onScreenCanvas.getView();
boolean started = view.isViewRunning();
if (started) { view.stopView(); }
view.addCanvas3D(offScreenCanvas);
if (started) { view.startView(); }
}

private void resizeImageBufferIfNeeded() {
boolean resize = false;
Rectangle rect = onScreenCanvas.getBounds();
if (this.offScreenImageBuffer == null) { resize = true; }
else {
if (offScreenImageBuffer.getWidth() != rect.getWidth()) { resize = true; }
if (offScreenImageBuffer.getHeight() != rect.getHeight()) { resize = true; }
}
if (!resize) { return; }

if(rect.width<=0) return; // Not sized yet
offScreenImageBuffer = new BufferedImage(rect.width, rect.height, BufferedImage.TYPE_INT_RGB);
ImageComponent2D comp = new ImageComponent2D(ImageComponent.FORMAT_RGB, offScreenImageBuffer, true, false);
offScreenCanvas.setOffScreenBuffer(comp);
}

/**

  • Get preferred configuration for Canvas3D.
  • This method is the same as SimpleUniverise.getPreferredConfiguration().
  • For dual monitor situations, it only works if the main application window
  • is on the primary monitor.
    *
  • @return
    */
    public static GraphicsConfiguration getPreferredConfiguration() {
    GraphicsConfigTemplate3D template = new GraphicsConfigTemplate3D();
    String stereo;

// Check if the user has set the Java 3D stereo option.
// Getting the system properties causes appletviewer to fail with a
// security exception without a try/catch.

stereo = (String) java.security.AccessController.doPrivileged(
new java.security.PrivilegedAction() {

public Object run()

{ return System.getProperty("j3d.stereo"); }
});

// update template based on properties.
if (stereo != null) {
if (stereo.equals("REQUIRED")) { template.setStereo(template.REQUIRED); }
else if (stereo.equals("PREFERRED")) { template.setStereo(template.PREFERRED); }
}

// Return the GraphicsConfiguration that best fits our needs.
return GraphicsEnvironment.getLocalGraphicsEnvironment().
getDefaultScreenDevice().getBestConfiguration(template);
}

/**
* Get a GraphicsConfiguration configured for Java3D for the target
* GraphicsDevice.
* The device should be the screen device for displaying the intended Canvas3D.
*
* @return
*/
public static GraphicsConfiguration getPreferredConfiguration(GraphicsDevice device) {

GraphicsConfigTemplate3D template = new GraphicsConfigTemplate3D();
String stereo;

// Check if the user has set the Java 3D stereo option.
// Getting the system properties causes appletviewer to fail with a
// security exception without a try/catch.

stereo = (String) java.security.AccessController.doPrivileged(
new java.security.PrivilegedAction() {

public Object run() { return System.getProperty("j3d.stereo"); }

});

// update template based on properties.
if (stereo != null) {
if (stereo.equals("REQUIRED"))

{ template.setStereo(template.REQUIRED); }

else if (stereo.equals("PREFERRED"))

{ template.setStereo(template.PREFERRED); }

}

// Return the GraphicsConfiguration that best fits our needs.
return device.getBestConfiguration(template);

}

/**

  • Get preferred configuration for Canvas3D for Canvas3D objects intended to be
  • added to the provided Window.
  • In multiple monitor situations you should pass the window to this method
  • and it will figure out the correct GraphicContext for the monitor holding the
  • target window.
    *
  • @return
    */
    public static GraphicsConfiguration getPreferredConfiguration(Window window) { GraphicsDevice device = window.getGraphicsConfiguration().getDevice(); return getPreferredConfiguration(device); }

/**

  • Adds a Java2DActor class to the Canvas3D components in this container.
  • Java2DActors perform post render drawing or other interactions on top of the
  • Canvas3D.
  • @param actor Adds this actor (not a clone) to the onScreenCanvas.
  • Adds a clone of this actor to the offscreen canvas.
    */
    public void addActor(Java2DActor actor)
    Unknown macro: { this.actors.add(actor); this.onScreenCanvas.addActor(actor); if (offScreenCanvas != null) { offScreenCanvas.addActor((Java2DActor) actor.clone()); } }

/**

  • Removes a Java2DActor class to the Canvas3D components in this container.
  • Java2DActors perform post render drawing or other interactions on top of the
  • Canvas3D.
  • @param actor
    */
    public boolean removeActor(Java2DActor actor)
    Unknown macro: { this.actors.remove(actor); boolean result = this.onScreenCanvas.removeActor(actor); if (offScreenCanvas != null) { offScreenCanvas.removeActor(actor); } return result; }

/**

  • This method detaches and removes the offscreen canvas. The offscreen
  • canvas is used for making screen shots of the view. It will be automatically
  • re-created when needed for a screenshot.
  • Due to issues in Java3D, this method must be called to
  • explicitly delete the offscreen canvas whenever certain view properties are changed
  • such as the projection policy, screen size, etc.
    */
    public void detachOffScreenCanvas() {
    if (offScreenCanvas != null)
    Unknown macro: { View oldView = offScreenCanvas.getView(); if (oldView != null) { oldView.removeCanvas3D(offScreenCanvas); } offScreenCanvas = null; offScreenImageBuffer = null; }

    }
    }



 Comments   
Comment by harveyh [ 10/Oct/12 ]

I've got a fork of the Java3d code up on github that has a JOGL2 backend, maybe you'll
have better luck with those:

https://github.com/hharrison/java3d-core
https://github.com/hharrison/java3d-utils
https://github.com/hharrison/vecmath

I'm working with the people at jogamp.org to get binary builds going again, feel free to
inquire in the java3d forum there if you have any questions...or if you have success.

Harvey





[JAVA3D-665] SimpleUniverse.getPreferredConfiguration() should throw an exception when no supported configuration is found Created: 03/Jul/11  Updated: 03/Jul/11

Status: Open
Project: java3d
Component/s: None
Affects Version/s: 1.5.2
Fix Version/s: None

Type: Improvement Priority: Major
Reporter: laeubi Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

At the momment SimpleUniverse.getPreferredConfiguration() returns null when no suitable configuration is found .

The API states:

Returns:
The best GraphicsConfiguration object for the system.

Either it should be made clear that it might return null or preferable throws an exception with the actual cause why no suitable configuration could be found (e.g. invalid GLX Version, unsupported driver/card, ...)






[JAVA3D-664] SIGSEGV while rendering Created: 03/Jul/11  Updated: 03/Jul/11

Status: Open
Project: java3d
Component/s: j3d-core
Affects Version/s: 1.5.2
Fix Version/s: None

Type: Bug Priority: Major
Reporter: laeubi Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Linux/Debian JDK 1.6


Attachments: Text File hs_err_pid17728.log     Text File hs_err_pid18120.log     Text File hs_err_pid19284.log    

 Description   

When resizing the window Java sometimes crash with a SIGSEGV (see attatchments).

It is then stuck and must be killed to terminate the VM.






[JAVA3D-660] Compatibility with JOGL v. 2 Created: 26/Mar/11  Updated: 06/Aug/13

Status: Open
Project: java3d
Component/s: j3d-core
Affects Version/s: 1.5.2, current, 1.6.0
Fix Version/s: None

Type: Bug Priority: Major
Reporter: schnied Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: 4 weeks
Time Spent: Not Specified
Original Estimate: 4 weeks
Environment:

All


Tags: gluegen, jocl, jogl

 Description   

Java developers are increasingly interested in using OpenCL - this will require compatibility between Java3D and Gluegen, JOGL and JOCL.

For example, Java3D 1.5.2 and 1.6.0 depend on the following JOGL v. 1.1.1 class:
javax/media/opengl/AbstractGraphicsDevice

However, this class has been replaced in JOGL v.2 by:
javax/media/nativewindow/AbstractGraphicsDevice



 Comments   
Comment by harveyh [ 06/Aug/13 ]

Java3d has been ported to use JOGL2 as the backend, code can be found here:

https://github.com/hharrison/vecmath
https://github.com/hharrison/java3d-core
https://github.com/hharrison/java3d-utils

You can get prebuilt jars from here:

http://jogamp.org/deployment/java3d/1.6.0-pre8/

There's a forum at forum.jogamp.org is you have any questions.

Harvey





[JAVA3D-661] sound rendering on view with single off screen canvas Created: 26/Apr/11  Updated: 26/Apr/11

Status: Open
Project: java3d
Component/s: None
Affects Version/s: 1.5.2
Fix Version/s: None

Type: Bug Priority: Major
Reporter: IanGee Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Windows XP, J3D 1.5.2, JOAL 1.1.1 and JOALMixer 1.5.2



 Description   

I'm developing a driving simulator for road safety training purposes.

I have created a multi-view universe (based on mirrordemo150.jar) to allow for the normal driver forward view to be rendered to the screen plus a rear view mirror image to be rendered to an off screen buffer, which is then copied to a texture and displayed in the mirror's position. This is all working fine.

However, the sound renderer is rendering sound from the rear view perspective. I do not seem to be able to set/reset this to the correct driver's view using the sound mixer setView() method. It appears the setView() method is being called by the J3D rendering loop - this also seems to be causing a non-fatal nullpointer error when it encounters the off screen canvas View object.

I'm not sure why the sound is not being rendered from the perspective of the on-screen active view. Indeed, I'm not sure why its continually rendering sound from the off screen rear view perspective, which is only rendered when the renderOffScreenBuffer() method is invoked.

I don't believe sound should ever normally be rendered for an off screen canvas/view - it simply makes no sense as the user is very unlikely to see the world from this perspective. In my experience, rendering to an off screen buffer is usually done to produce an image for a real-time texture or environment map - e.g. a reflection, or an in-game CCTV image...

Is this a bug? Is there a way to disable sound rendering on a particular View object?
Is maintaining two separate universes, one for on-screen Views with sound and one for off-screen Views with no sound, the only way to overcome this issue?






[JAVA3D-662] Fatal NullPointerException in ViewSpecificGroup Created: 27/Apr/11  Updated: 27/Apr/11

Status: Open
Project: java3d
Component/s: None
Affects Version/s: 1.5.2
Fix Version/s: None

Type: Bug Priority: Major
Reporter: IanGee Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Windows XP, JOALMixer 1.5.2



 Description   

Further to issue 661.

Added a ViewSpecificGroup to isolate sounds meant for the on screen canvas View object.

Following error occurs on scene initialization:

Exception in thread "J3D-SoundSchedulerUpdateThread-1" java.lang.NullPointerException
at javax.media.j3d.SoundStructure.isSoundScopedToView(SoundStructure.java:640)
at javax.media.j3d.SoundScheduler.changeNodeState(SoundScheduler.java:553)
at javax.media.j3d.SoundScheduler.processMessages(SoundScheduler.java:221)
at javax.media.j3d.StructureUpdateThread.doWork(StructureUpdateThread.java:102)
at javax.media.j3d.J3dThread.run(J3dThread.java:275)

This seems to occur irrespective of the sound mixer being used...and even occurs when a sound mixer is not running.






[JAVA3D-659] Diferent Texturerendering Created: 07/Mar/11  Updated: 08/Mar/11

Status: Open
Project: java3d
Component/s: None
Affects Version/s: not determined
Fix Version/s: None

Type: Bug Priority: Major
Reporter: Schreck Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: JPEG File resultA.jpg     JPEG File resultB.jpg     JPEG File resultC.jpg     JPEG File resultD.jpg     Java Source File Universe.java    
Tags: Direct3D, OpenGL, Texture

 Description   

Hi,
I'm a new Java3D developer. I found some diferences und varios Machines and Rendering methodes. The sourcecode is a Democode from "Virtual Worlds Productions / Michael Pfeiffer". Here are the results:

Hardware Machine 1:
Mobile Intel(R) GMA X3100
Video-RAM: 358 MB

Software
Windows 7 (32Bit)
Java 1.6.0_23 (32Bit)

j3d Version 1.3.2 + 1.4.0.1
OGL: Result A / D3D: Result D

j3d Version 1.5.0 + 1.5.1 + 1.5.2
OGL: Result A / D3D: Result C

Linux 2.6.32 (Ubuntu 10.04)
Java 1.6.0_24
j3d Version 1.5.2

OGL: Result A

==========

Hardware Machine 2:
Intel(R) 82852/82855 GM/GME Graphics Controller
Video-RAM: 64 MB

Software
Windows XP (32Bit)
Java 1.6.0_20 (32Bit)
j3d Version 1.5.2

OGL: Result C / D3D: Result C

==========

Hardware Machine 3:
ATI Radeon 9600 Series AGP (0x4150)
Video-RAM: 128 MB

Software
Windows XP (32Bit)
Java 1.6.0_?? (32Bit)
j3d Version 1.5.2

OGL: Result A / D3D: Result B

==========

Hardware Machine 4:
ATI Radeon X1200 Series (Microsoft Coorperation - WDDM)
Video-RAM: 831 MB

Software
Windows 7 (64Bit)
Java 1.6.0_23 (32Bit)

j3d Version 1.3.2
OGL: Result A / D3D: Result D

j3d Version 1.4.0.1
OGL: ERROR / D3D: Result D

j3d Version 1.5.0
OGL: ERROR / D3D: Result C

j3d Version 1.5.1 + 1.5.2
OGL: Result C / D3D: Result C

==========

Hardware Machine 5:
ATI Radeon 2100 (Microsoft Coorperation - WDDM)
Video-RAM: 1407 MB

Software
Windows 7 (64Bit)
Java 1.6.0_23 (32Bit)
j3d Version 1.5.2

OGL: Result C / D3D: Result C

==========

Hardware Machine 6:
NVIDIA GeForce 8400 GS
Video-RAM: 1023 MB

Software
Windows 7 (64Bit)
Java 1.6.0_23 (32Bit)
j3d Version 1.5.2

OGL: Result A / D3D: Result C

==========

Hardware Machine 7:
NVIDIA Quadro FX 550
Video-RAM: 383 MB

Software
Windows 7 (64Bit)
Java 1.6.0_23 (32Bit)

j3d Version 1.4.0.1
OGL: Result A / D3D: Result D

j3d Version 1.5.2
OGL: Result A / D3D: Result C



 Comments   
Comment by Schreck [ 08/Mar/11 ]

I am Sorry for my bad english...

The text above is not correct. I'm a new USER from Java3D. I need some help to use Java3D on all my computers with the same result. When you need more tests, please write me. When I can help you by another way, please write me. But I don't have knowlege about pure OpenGL or Direct3D... I'm sorry.





[JAVA3D-676] JAVA application crashes when tried to open 3D canvas Created: 09/Oct/14  Updated: 09/Oct/14

Status: Open
Project: java3d
Component/s: None
Affects Version/s: 1.5.2
Fix Version/s: None

Type: Bug Priority: Major
Reporter: kwang Assignee: kcr
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Windows 7 professional 32bits, Java 1.7.0_60



 Description   

DefaultRenderingErrorListener.errorOccurred:
CONTEXT_CREATION_ERROR: Renderer: Error creating Canvas3D graphics context
graphicsDevice = Win32GraphicsDevice[screen=0]
canvas = com.vassolinc.i.i[canvas0,0,0,494x488]
shut down Java virtual machine.






[JAVA3D-666] null-pointer or indexoutofbound crash in GeometryAtom::getRenderAtom Created: 18/Jul/11  Updated: 18/Nov/16

Status: Open
Project: java3d
Component/s: j3d-core
Affects Version/s: 1.5.2, current, 1.6.0
Fix Version/s: None

Type: Bug Priority: Major
Reporter: harveyh Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Windows XP and Windows 7 32 and 64bit



 Description   

The locking of the renderAtoms array is not correct and can allow multiple
threads to overwrite the array during concurrent calls.

The problem arises due to using renderAtoms as the object to synchronize on
and then updating the renderAtoms reference inside the synchronized block.

Patch to follow after a bit more testing.



 Comments   
Comment by harveyh [ 19/Jul/11 ]

From: Harvey Harrison <harvey.harrison@gmail.com>
Date: Tue, 19 Jul 2011 10:08:43 -0700
Subject: [PATCH] java3d: use consistent locking when updating the renderAtoms array

You cannot lock updates to a member variable using itself if the reference is
ever changed. The renderAtoms array in GeomtryAtom is resized when it does not
have enough room for all the open views. This leads to crashes similar to the following:

Exception in thread "J3D-RenderStructureUpdateThread-6" java.lang.ArrayIndexOutOfBoundsException: 5
at javax.media.j3d.GeometryAtom.getRenderAtom(GeometryAtom.java:236)
at javax.media.j3d.RenderBin.removeNodes(RenderBin.java:6848)
at javax.media.j3d.RenderBin.processMessages(RenderBin.java:1374)
at javax.media.j3d.StructureUpdateThread.doWork(StructureUpdateThread.java:97)
at javax.media.j3d.J3dThread.run(J3dThread.java:270)

Use the existing lockObj in this class to synchronize access. This lock is already
being used to protect updates to the centroid update calculation, but both locked
sections are relatively short, if contention ends up being a problem, renderAtoms
could be changed to an ArrayList instead which can be resized or another lockObj could be added.

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>

src/javax/media/j3d/GeometryAtom.java | 2 +-
1 files changed, 1 insertions, 1 deletions

diff --git a/src/javax/media/j3d/GeometryAtom.java b/src/javax/media/j3d/GeometryAtom.java
index 235f549..6ec0ab8 100644
— a/src/javax/media/j3d/GeometryAtom.java
+++ b/src/javax/media/j3d/GeometryAtom.java
@@ -159,7 +159,7 @@ class GeometryAtom extends Object implements BHLeafInterface, NnuId {
// If renderAtom is not scoped to this view, don't even
// bother creating the renderAtom

  • synchronized (renderAtoms) {
    + synchronized (lockObj) {
    index = view.viewIndex;
    if (index >= renderAtoms.length) {
Comment by mcneillk [ 20/Jul/11 ]

Thank you Harry. If we can get that test case, I can proceed to validate the issue.

However, I'm a little confused as to why the line number (236) that you site in GeometryAtom.java does NOT match the current Java 3D source from SVN...

Ken

Comment by harveyh [ 20/Jul/11 ]

Sorry about the line-number confusion, I was running with some debugging code while tracing this issue and kept the stacktrace from one of those runs.

I'm afraid it's going to be a bit difficult to distill a testcase for this as it comes from an
internal engineering app I'm not at liberty to distribute.

Comment by harveyh [ 20/Jul/11 ]

OK, I went back and verified the steps I took to track this bug down and found I was
missing one hunk in my patch....thanks for questioning it!

On an unpatched svn checkout (dev-1_6) branch I see the following (within about 10 seconds):

Exception in thread "J3D-RenderStructureUpdateThread-6" java.lang.ArrayIndexOutOfBoundsException: 5
at javax.media.j3d.GeometryAtom.getRenderAtom(GeometryAtom.java:242)
at javax.media.j3d.RenderBin.removeNodes(RenderBin.java:6843)
at javax.media.j3d.RenderBin.processMessages(RenderBin.java:1369)
at javax.media.j3d.StructureUpdateThread.doWork(StructureUpdateThread.java:102)
at javax.media.j3d.J3dThread.run(J3dThread.java:275)

This part is due to the final return renderAtoms[index] not being inside the synchronized
block, moving the return inside the synchronized block then reliably produces the following:

Exception in thread "J3D-RenderStructureUpdateThread-4" java.lang.ArrayIndexOutOfBoundsException: 4
at javax.media.j3d.GeometryAtom.getRenderAtom(GeometryAtom.java:179)
at javax.media.j3d.RenderBin.removeNodes(RenderBin.java:6842)
at javax.media.j3d.RenderBin.processMessages(RenderBin.java:1369)
at javax.media.j3d.StructureUpdateThread.doWork(StructureUpdateThread.java:102)
at javax.media.j3d.J3dThread.run(J3dThread.java:275)

Which occurs as multiple threads can run through this section as each thread updates renderAtoms.

The second part of the patch then uses the lockObj to synchronize all of these accesses
and has run for > 12 hours now without fail. It has pointed out another bug in OrderedBin
which uses the same bad locking pattern.

Turns out the tool FindBugs has a pattern for exactly this locking pattern, and finds 4 instances in Java3d, which I'll submit as separate reports.

The full patch:

src/javax/media/j3d/GeometryAtom.java | 7 ++++---
1 files changed, 4 insertions, 3 deletions

diff --git a/src/javax/media/j3d/GeometryAtom.java b/src/javax/media/j3d/GeometryAtom.java
index e7286db..191468f 100644
— a/src/javax/media/j3d/GeometryAtom.java
+++ b/src/javax/media/j3d/GeometryAtom.java
@@ -165,7 +165,7 @@ class GeometryAtom extends Object implements BHLeafInterface, NnuId {
// If renderAtom is not scoped to this view, don't even
// bother creating the renderAtom

  • synchronized (renderAtoms) {
    + synchronized (lockObj) {
    index = view.viewIndex;
    if (index >= renderAtoms.length) {

@@ -237,9 +237,10 @@ class GeometryAtom extends Object implements BHLeafInterface, NnuId {
}
}
}
+ return (renderAtoms[index]);
}

  • return (renderAtoms[index]);
    +
    +
    }
    // If the renderAtom is transparent, then make sure that the
    // value is up-to-date

    • 1.7.4.msysgit.0
Comment by TearRel [ 18/Nov/16 ]

I've got problem with exception mentioned above:
at javax.media.j3d.GeometryAtom.getRenderAtom(GeometryAtom.java:242).
Is there any solution for this issue?

Comment by harveyh [ 18/Nov/16 ]

Fixed here in my Java3D fork:

https://github.com/hharrison/java3d-core/commit/3bd82be0371e40390abc5509cb2a7d6e3a055a12

Updated jars here:

https://github.com/hharrison/java3d-core/releases/tag/1.6.0

Not my fork does not contain any of the native backends and relies entirely on the JOGL project, version 2.3.2.

Good luck.

Harvey





[JAVA3D-670] java3d needs to load Created: 23/Oct/11  Updated: 23/Oct/11

Status: Open
Project: java3d
Component/s: j3d-core-utils
Affects Version/s: 1.4.0-dev
Fix Version/s: None

Type: Task Priority: Minor
Reporter: riddle Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified





[JAVA3D-663] Forgotten comment in MouseBehavior Created: 20/May/11  Updated: 20/May/11

Status: Open
Project: java3d
Component/s: j3d-core-utils
Affects Version/s: current
Fix Version/s: None

Type: Bug Priority: Trivial
Reporter: peci1 Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: 1 minute
Time Spent: Not Specified
Original Estimate: 1 minute
Environment:

Java3D 1.5.2, but I've found out that this bug is in Java3D since 2005...


Tags: comment, mousebehavior

 Description   

com.sun.j3d.utils.behaviors.mouse.MouseBehavior
Line 341 should have been commented out (a System.out.println()), but the author forgot to do so.

Nothing horrible, just overriding the mouseWheelMoved() will workaround the prints to sysout, but it's obviously a bug.






Generated at Sun Dec 04 11:03:37 UTC 2016 using JIRA 6.2.3#6260-sha1:63ef1d6dac3f4f4d7db4c1effd405ba38ccdc558.