#jogamp @ irc.freenode.net - 20150709 05:06:24 (UTC)


20150709 05:06:24 -jogamp- Previous @ http://jogamp.org/log/irc/jogamp_20150708050624.html
20150709 05:06:24 -jogamp- This channel is logged @ http://jogamp.org/log/irc/jogamp_20150709050624.html
20150709 06:36:15 * elect (~elect@anon) has joined #jogamp
20150709 06:51:49 * rmk0 (~rmk0@anon) has joined #jogamp
20150709 06:51:50 * rmk0 (~rmk0@anon) Quit (Changing host)
20150709 06:51:50 * rmk0 (~rmk0@anon) has joined #jogamp
20150709 07:07:52 * monsieur_max (~maxime@anon) has joined #jogamp
20150709 07:25:54 <elect> hi
20150709 07:56:45 <elect> I dont get, I keep having exception with the buffer#
20150709 07:57:05 <elect> float[] view = ViewPole.instance.calcMatrix().toFloatArray();
20150709 07:57:05 <elect> float[] proj = ViewPole.instance.getVehicleProjMatrix().toFloatArray();
20150709 07:57:05 <elect> FloatBuffer floatBuffer = GLBuffers.newDirectFloatBuffer(view.length + proj.length);
20150709 07:57:05 <elect> floatBuffer.put(view, 0, view.length);
20150709 07:57:05 <elect> System.out.println(""+floatBuffer.toString());
20150709 07:57:06 <elect> floatBuffer.put(proj, view.length, proj.length);
20150709 07:57:17 <elect> view and proj are 16 float long
20150709 07:57:50 <elect> floatbuffer is 32 slots big
20150709 07:58:29 <elect> but when I try to put the proj in the floatBuffer I get outOfBoundaries
20150709 07:59:29 * gouessej (5ee4b442@anon) has joined #jogamp
20150709 07:59:39 <elect> hi gouessej
20150709 07:59:48 <gouessej> Hi
20150709 07:59:54 <gouessej> I'm looking at your stuff
20150709 07:59:59 <gouessej> It's a RELATIVE put
20150709 08:00:02 <elect> bindless
20150709 08:00:05 <elect> ah
20150709 08:00:15 <gouessej> Please read the documentation: http://docs.oracle.com/javase/7/docs/api/java/nio/FloatBuffer.html#put(float[],%20int,%20int)
20150709 08:00:21 <elect> are you looking at the log?
20150709 08:00:24 <gouessej> Yes
20150709 08:01:02 <elect> so basically after the first put
20150709 08:01:03 <gouessej> I'm always looking at the logs except when I sleep, eat, work, make love, ...
20150709 08:01:10 <elect> pointer is at index 15?
20150709 08:01:19 <elect> :D
20150709 08:02:01 <gouessej> Yes, look at the example wihtin the documentation, it's crystal clear
20150709 08:02:14 <gouessej> for (int i = off; i < off + len; i++) dst.put(a[i]);
20150709 08:02:41 <elect> yep
20150709 08:02:42 <elect> i saw
20150709 08:02:52 <gouessej> xranby: Good finding, I have looked at the bug 1166 :)
20150709 08:02:54 <elect> you are my god
20150709 08:02:59 <elect> merci
20150709 08:03:07 <gouessej> There is no god. You're welcome.
20150709 08:03:15 <elect> anyway, do you have any other tip for the bindless sample?
20150709 08:03:23 <gouessej> Sorry to hurt the believers... oops
20150709 08:03:43 <elect> I got rid of all awt, I had a small improvement, but yet far away from the C version
20150709 08:04:22 <elect> moreover, you mentioned also "no bridge"
20150709 08:04:25 <elect> what you meant?
20150709 08:05:00 <gouessej> You can run the simple example written by Xerxes (see the wiki) and port it back to C in order to compare the frame rate before using your more complicated example
20150709 08:05:23 <gouessej> I meant no bridge between several UI toolkits
20150709 08:06:01 * jvanek (jvanek@anon) has joined #jogamp
20150709 08:06:18 <elect> you mean this one
20150709 08:06:19 <elect> http://jogamp.org/git/?p=jogl-demos.git;a=blob;f=src/demos/es2/RawGL2ES2demo.java;hb=HEAD
20150709 08:06:25 <gouessej> outOfBoundaries meant IndexOutOfBoundsException
20150709 08:06:29 <gouessej> yes
20150709 08:09:39 <gouessej> Actually, System.exit(0) should be called only if Java Webstart is in use
20150709 08:09:49 <gouessej> Otherwise, it's useless
20150709 08:10:06 <gouessej> I'm talking about the source code above
20150709 08:10:55 * eclesia (~husky@anon) has joined #jogamp
20150709 08:11:01 <eclesia> good morning
20150709 08:11:22 <elect> ok
20150709 08:11:37 <elect> I also dont use webstart
20150709 08:13:40 <elect> anyway gouessej, it is strange because I used some gpu timers, and the time my display() takes seems totally normal
20150709 08:14:00 <elect> so this is why I assume it is something outside my competences
20150709 08:14:41 <gouessej> What do you mean by "normal"?
20150709 08:18:47 <elect> even faster than those of the C
20150709 08:19:22 <elect> and the end gpu timer is read whenever all the gpu operation are terminated
20150709 08:21:13 <gouessej> If the time spent in GLEventListener.display() isn't surprising, what is still wrong?
20150709 08:22:43 <gouessej> For others, Java Webstart is in use if javax.jnlp.ServiceManager.getServiceNames() != null: http://stackoverflow.com/a/16200769
20150709 08:23:28 <gouessej> Oops, rather catch UnavailableServiceException
20150709 08:23:44 <elect> the framerate is so low
20150709 08:23:51 <elect> 200 fps vs 4/600
20150709 08:24:08 <elect> so something outside display() is killing performances
20150709 08:25:49 <gouessej> Yes, it's possible
20150709 08:37:31 <gouessej> Do you call Thread.sleep() or yield()?
20150709 08:40:09 <elect> no
20150709 08:40:13 <elect> not at all
20150709 08:47:01 <gouessej> Are you under Windows when you run your test?
20150709 08:53:40 <elect> both Win and Linux
20150709 08:55:01 <gouessej> The high resolution timer isn't used by default under Windows
20150709 08:55:42 <gouessej> Why not using our timers instead of yours?
20150709 08:56:09 <elect> im using the GL ones
20150709 08:56:53 <elect> gl4.glGetQueryObjecti64v(queryId[0], GL4.GL_QUERY_RESULT, frameGpuTime, 0);
20150709 08:57:17 <elect> which ones shall I use?
20150709 08:57:20 <gouessej> You don't use FPSCounter, do you? Do you use your NvStopWatch class?
20150709 08:59:14 <elect> those are just class timer implemented in the system
20150709 08:59:22 <elect> *sample
20150709 08:59:30 <elect> anyway I am not relying on them right now
20150709 09:00:22 <elect> Im counting the total number of frame
20150709 09:00:27 <elect> with a simple variable
20150709 09:00:55 <elect> and I am also using animator.setUpdateFPSFrames(100, System.out);
20150709 09:14:21 <gouessej> Do you use Animator.setRunAsFastAsPossible(true)?
20150709 09:15:24 * badshah400 (~badshah40@anon) has joined #jogamp
20150709 09:18:57 <gouessej> if ( !runAsFastAsPossible ) { // Avoid swamping the CPU Thread.yield(); }
20150709 09:19:07 <gouessej> https://github.com/sgothel/jogl/blob/master/src/jogl/classes/com/jogamp/opengl/util/Animator.java#L204
20150709 09:25:00 <elect> Ah, I didnt know that, anyway runAsFastAsPossible is true animator.setRunAsFastAsPossible(true);
20150709 09:40:39 <gouessej> I advise you to use a profiler. I have found nothing obviously wrong in your code
20150709 09:42:55 <gouessej> It's a bit strange to call glad.swapBuffers() and then perform a few OpenGL calls just after
20150709 09:44:09 <gouessej> In my humble opinion, it's not JOGL related as it doesn't happen in GLEventListener.display()
20150709 09:46:33 <gouessej> Why is animator.setExclusiveContext(t) commented?
20150709 09:51:22 * gouessej (5ee4b442@anon) Quit (Quit: Page closed)
20150709 11:17:51 * badshah400 (~badshah40@anon) Quit (Ping timeout: 264 seconds)
20150709 13:16:28 <xranby> gouessej: thank you for reviewing 1166, i have sent a pull request to sgothel to merge solution C
20150709 15:03:39 * jvanek (jvanek@anon) Quit (Quit: Leaving)
20150709 15:03:56 * jvanek (jvanek@anon) has joined #jogamp
20150709 15:03:56 * jvanek (jvanek@anon) Quit (Client Quit)
20150709 15:28:27 * elect (~elect@anon) Quit (Ping timeout: 255 seconds)
20150709 15:53:32 * monsieur_max (~maxime@anon) Quit (Quit: Leaving.)
20150709 16:04:14 * eclesia (~husky@anon) has left #jogamp
20150709 16:06:40 * elect (~elect@anon) has joined #jogamp
20150709 16:51:37 * monsieur_max (~maxime@anon) has joined #jogamp
20150709 16:54:51 <elect> xranby, in your sample http://jogamp.org/git/?p=jogl-demos.git;a=blob;f=src/demos/es2/RawGL2ES2demo.java;hb=HEAD you are not stopping the animator before quitting
20150709 17:30:52 <xranby> elect: probably should do that then , to remove the extra warnings
20150709 17:53:18 * elect (~elect@anon) Quit (Ping timeout: 248 seconds)
20150709 19:24:39 * elect (~elect@anon) has joined #jogamp
20150709 21:21:18 * elect (~elect@anon) Quit (Ping timeout: 248 seconds)
20150709 21:28:51 * xranby_ (~familjen@anon) Quit (Ping timeout: 265 seconds)
20150709 21:28:54 * monsieur_max (~maxime@anon) Quit (Quit: Leaving.)
20150709 21:31:58 * xranby_ (~familjen@anon) has joined #jogamp
20150710 05:06:24 -jogamp- Continue @ http://jogamp.org/log/irc/jogamp_20150710050624.html