Author Topic: Now this looks like a Java 10 Thing  (Read 3183 times)

Offline AGP

  • quad
  • ******
  • Posts: 1726
    • View Profile
Now this looks like a Java 10 Thing
« on: April 29, 2018, 11:45:19 pm »
I was working a while ago on this fire particle system. I don't remember the rendering getting clipped like this.

Code: [Select]
this.setSize(buffer.getOutputWidth(), buffer.getOutputHeight());
this.add(canvas, BorderLayout.CENTER);
this.setVisible(true);
...
     buffer.clear(Color.blue);
     flameManager.update(deltaTime);
     smokeManager.update(deltaTime);
     skyBox.render(theWorld, buffer);
     if (!doShadows()) {
theWorld.renderScene(buffer);
theWorld.draw(buffer);
     }
     buffer.update();
     buffer.displayGLOnly();
     canvas.repaint();

https://www.dropbox.com/s/jpkrg93a6vi03db/ClippingThing.jpg?dl=0

Offline AGP

  • quad
  • ******
  • Posts: 1726
    • View Profile
Re: Now this looks like a Java 10 Thing
« Reply #1 on: April 30, 2018, 12:03:27 am »
Update: everything that uses the canvas has that problem.

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 12295
    • View Profile
    • http://www.jpct.net
Re: Now this looks like a Java 10 Thing
« Reply #2 on: May 01, 2018, 01:09:55 pm »
Works just fine for me. Can you provide me with the complete, executable test case?

Offline AGP

  • quad
  • ******
  • Posts: 1726
    • View Profile
Re: Now this looks like a Java 10 Thing
« Reply #3 on: May 02, 2018, 06:00:56 am »
I'll make one but it's either Java 10 or some Windows graphics-related update. All of my AWTGLCanvas programs are now suffering from this. It's important to note that while the graphics are getting offset, the mouse events are where they belong. Also, even as the graphics are offset, the FrameBuffer colors the entire frame whatever background color I assign clear(Color).

Offline AGP

  • quad
  • ******
  • Posts: 1726
    • View Profile
Re: Now this looks like a Java 10 Thing
« Reply #4 on: May 10, 2018, 06:49:54 pm »
I've tried both -Dsun.java2d.d3d=false and -Dsun.java2d.opengl=false. Neither has solved this annoying issue. One of the reasons I so like the software renderer right there. Still, I'd like for this to go away.