Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Jakes

Pages: 1 2 [3] 4 5
31
Support / Loading performance - Cotninuation
« on: January 19, 2020, 09:43:10 pm »
Hello,

after the recent topic "Low performance when using uncompiled objects", the mais issue seemed to be the preWarming of textures, which seems to be solved.

Altought, when using a huge cluster of objects of the same type, there seems to happen a loading of some sort, while the console is outputting these:

Not a triangle strip at position 1!
Remapping 2022 vertex indices!
Creating vertex cache (48528 bytes)!
Vertex indices will be mapped!
Subobject of object 0/object2 compiled to indexed data using 4932/4932 vertices in 20ms!
Checking for triangle strip...
Compiling source object...
Checking for triangle strip...
Not a triangle strip at position 1!
Remapping 68 vertex indices!
Creating vertex cache (1632 bytes)!
Vertex indices will be mapped!
Subobject of object 2/object4 compiled to indexed data using 102/102 vertices in 2ms!
Object 2/object4 compiled to 1 subobjects in 2ms!
Object 5233/object5235 precompiled!
Compiling source object...
Checking for triangle strip...
Not a triangle strip at position 1!
Remapping 162 vertex indices!
Creating vertex cache (3888 bytes)!
Vertex indices will be accessed directly!
Subobject of object 6/object8 compiled to indexed data using 960/960 vertices in 5ms!
Object 6/object8 compiled to 1 subobjects in 6ms!
Object 5234/object5236 precompiled!
Object 5235/object5237 precompiled!
Delayed pre-warming done!
VBO created for object 'object5226'
VBO created for object 'object5220'
Compiled 2 VBO!
Object 'object3482' shares compiled data with object 'object11'
Object 'object4333' shares compiled data with object 'object11'
Object 'object3152' shares compiled data with object 'object11'
Object 'object4338' shares compiled data with object 'object11'
Object 'object2954' shares compiled data with object 'object11'
[x 1000 more]
...

Checking for triangle strip...
Not a triangle strip at position 1!
Subobject of object 5239/object5241 compiled to indexed data using 24/9 vertices in 1ms!
Object 5239/object5241 compiled to 1 subobjects in 1ms!
Object 5242/object5244 precompiled!
Object 5243/object5245 precompiled!
Checking for triangle strip...
Not a triangle strip at position 1!
Subobject of object 5246/object5248 compiled to indexed data using 24/9 vertices in 0ms!
Object 5246/object5248 compiled to 1 subobjects in 1ms!
Object 5249/object5251 precompiled!
Object 5250/object5252 precompiled!
Checking for triangle strip...
Not a triangle strip at position 1!
[x 1000 more]
...

Checking for triangle strip...
Not a triangle strip at position 1!
Subobject of object 5785/object5787 compiled to indexed data using 24/9 vertices in 0ms!
Object 5785/object5787 compiled to 1 subobjects in 1ms!
Object 5788/object5790 precompiled!
Object 5789/object5791 precompiled!
VBO created for object 'object5451'
VBO created for object 'object5409'
VBO created for object 'object5570'
VBO created for object 'object5598'
VBO created for object 'object5591'
VBO created for object 'object5731
VBO created for object 'object5444'
VBO created for object 'object5514'
VBO created for object 'object5647'
VBO created for object 'object5255'
VBO created for object 'object5696'
VBO created for object 'object5633'
VBO created for object 'object5521'
VBO created for object 'object5353'
VBO created for object 'object5773'
VBO created for object 'object5640'
VBO created for object 'object5549'
VBO created for object 'object5542'
VBO created for object 'object5710'
VBO created for object 'object5724'
VBO created for object 'object5479'
VBO created for object 'object5605'
VBO created for object 'object5689'
VBO created for object 'object5752'
VBO created for object 'object5703'
VBO created for object 'object5668'
VBO created for object 'object5654'
VBO created for object 'object5766'
VBO created for object 'object5759'
VBO created for object 'object5437'
VBO created for object 'object5528'
VBO created for object 'object5619'
VBO created for object 'object5500'
VBO created for object 'object5262'
VBO created for object 'object5311'
VBO created for object 'object5745'
VBO created for object 'object5465'
VBO created for object 'object5388'
Compiled 79 VBO!
Object 'object5301' shares compiled data with object 'object4'
Object 'object5623' shares compiled data with object 'object4'
Object 'object5595' shares compiled data with object 'object4'
Object 'object5588' shares compiled data with object 'object4'
Object 'object5448' shares compiled data with object 'object4'
Object 'object5462' shares compiled data with object 'object4'
Object 'object5315' shares compiled data with object 'object4'
Object 'object5700' shares compiled data with object 'object4'
Object 'object5567' shares compiled data with object 'object4'


during this period, a huge freeze starts and only stops after these have stop writing to the console.

The last JAR that was made to solve the preWarm issue, seems to lack the "World.compileAllObjects(FrameBuffer)" which I think could solve this loading process?

can you please add both changes to one last jar, if it's not too much trouble?

So my question is:
Could this be the cause?
If not, is there anything I can do before starting the scene to avoid this altogether?


I've even removed all the textures from my scene in order to dismiss this possibility, and it still happens, and the more objects I add onto the scene, the more this "loading period" takes. It's a bit nerve wracking because the number of objects is not that great and I'm not even in the middle of the development.

PS: I tried to use the "Config.glVerbose = false" to hide the previous log text, but it seems that some text is always being output, is it possible to reduce these info lines with an option? (any log describing the compilation process at runtime)

many thanks,

Jakes

32
Support / Re: Low performance when using uncompiled objects
« on: November 20, 2019, 11:33:27 am »
It worked!

Finally I can run the simulation in a smoother way, and it keeps stable without any staggering along the way.

BTW, I'm only using the TextureManager.preWarm(), the World.prewarmCompiledObjects() for some reason changed my objects orientation, prolly because of the "building" process of those objects. I'll have a look into it afterwards.

But thanks again man, if you want to publish that I'll download the offical version from the site.

I think this thread can finally rest now after a month of intense testing.

Regards,
Jakes

33
Support / Re: Low performance when using uncompiled objects
« on: November 19, 2019, 11:42:00 am »
Yes, I'm sorry I wasn't clear about that.

Yeah, I'm using the separate canvas because I'm writing an editor tool with some AWT components on the side, so it helps using a smaller viewport mixed with other stuff.

and yes, I figured that was the reason, since there are no syncronization wit this component. Well, thanks a lot, if you need any help on my side, just let me know.

34
Support / Re: Low performance when using uncompiled objects
« on: November 16, 2019, 04:25:30 am »
Found it!

It seems that the AWTJPCTCanvas is not assuming the preWarm action.

Here is my test example in attachment: Link

I've tested with 2 spheres with 2 4096x textures each, every time each one comes to play, there's a short freezing of the simulation.

I checked that this behavior doesn't apply when using the LWJGL Display combined with the preWarm, but when I'm using the Canvas generated by the "FrameBuffer.enableGLCanvasRenderer()" the preWarm seems to be ignored as you can check on this image below:


35
Support / Re: Low performance when using uncompiled objects
« on: November 15, 2019, 04:20:05 pm »
These textures vary from 512x512 to 4096x4096, the ones giving the major hiccups are the 2048x2048 and 4096x4096. when I removed them, everything worked fine, without hiccups at all (some so small you wodnt notice them 512 textures were harmless), using both the old and new jars.

So I removed the preWarm() I was using, and chaged it to the first cycle iteration of the simulation progress, and still had the same results as if there were no effect at all.
The example was a sphere with a 4096x4096 texture on it and 2 more of the same size with alpha channels. (only right before looking at the object you will have a small freeze-frame for 0.3/4 secs and it would continue normally afterwards)

I am building a single case scenario now with the same example, to test on my other machine, I will send you today the results and the project if you want them.

36
Support / Re: Animation Interpolation Between Sequences
« on: November 14, 2019, 12:56:13 am »
...It might be better to create different animations out of the individual frames and do the blending. You can reuse the frames, so it's not a memory issue.

thanks, will try out that.

37
Support / Re: Low performance when using uncompiled objects
« on: November 13, 2019, 07:02:46 pm »
So, I've run some tests with a lot of different cases, and it seems that everything seemed to be fine with the structures.

I ran some detailed analysis, and I haven't checked any differences whatsoever while using the new Jars, the problem persisted, so I took it a little deeper.

And I found that:
- New tests (with and without the new Jars) indicate that without textures the issue is non-existent.

So I tried to use the TextureManager.preWarm(FrameBuffer) (which I was already using before) in different moments and events, but to no success.
So I was reading the Wiki, and it says: "This method isn't guaranteed to do anything, if the renderer doesn't offer any pre-warming." -> Could it be this? How can I check this?

So, in conclusion it seems that the issue only exists when using big-textured compiled objects, otherwise, it runs smoothly regardless of the numer of vertices/faces or count. The staggering only happens every time a new texture comes to play stuck on an object.

PS: I'm trying to arrange a different setup/machine to try to test out the different scenarios to check if the issues are Mesh, VBO, Display List, Texture or Graphics card related.

38
Support / Re: Low performance when using uncompiled objects
« on: November 11, 2019, 12:05:19 pm »
So I tried to set Config.glUseVBO to false, and did a lot of different combinations and cases, and still got the same results, perhaps my graphics card always tends to use VBO? Some say that the latest cards only have support for VBO and Display Lists are becoming deprecated.

I also tried with uncompiled objects (with and without textures, with more or less objects) but got to the same result.

Quote
Try this one. It should also prefill the VBO: https://jpct.de/download/net/jpct.jar

Thanks, I'll give it a go when I get home later on.

Btw, no need to call World.compileAllObjects(FrameBuffer) or any other method on this change?


39
Support / Re: Low performance when using uncompiled objects
« on: November 07, 2019, 04:29:13 pm »
I've gathered some information while browsing the web and came across something similar:
  https://community.khronos.org/t/opengl-glbufferdata-cause-stuttering-while-loading-terrain-lod/76292/11

And something to try to solve the asyncronous problem:
  https://www.gamedev.net/forums/topic/677398-opengl-check-if-vbo-upload-is-complete/

but from what I can tell, this seem to be a known problem, and hard to deal with.

My idea is to try to load each object individually in front of the camera, behind an overlay that conceals it so that it can be loaded beforehand in order to avoid any future stuttering of the simulation. Do you whink this will solve the issue itself?



40
Support / Re: Low performance when using uncompiled objects
« on: November 07, 2019, 04:16:18 pm »
So I tested it out yesterday, and apparently 2 results happened:

- I tested it after the GL context is created (meaning a FrameBuffer) and nothing much changed, perhaps due to the GL data being sent through the pipeline for the first time as you said before.
- I tested it the first time an iteration happens (onProgress) to guarantee that there is in fact an existent GL context, but the result is mostly the same, sometimes faster but its non-deterministic, which I think might have to do with the loading of the GL VBOs into the GPU.

now my question is: How come we can't pre-load all these beforehand on a loading moment, so that those mid simulation loadings are avoided altogether?
Other frameworks allow for a preloading of all data (Textures, animations and 3Dobject models), no? Because no other game or simulation, I ran before, ever done that while in the middle of a running scene.

Isn't there any way to pass all the VBO data into the GPU synchronously beforehand and receive an "ok" when its done so I can progress further on loading the next ones before I can start the simulation itself? (Something like loading a texture, where you send the pixeldata to the GPU and it responds back with ok or not ok, and you proceed to load the next one?)

41
Support / Re: Animation Interpolation Between Sequences
« on: November 07, 2019, 03:46:28 pm »
Ok, so that kinda solves half the problem, which is only connected sequences will be interpolated, but if I want to interpolate 1 and 2, 1 and 3, 1 and 4, is there a way to override anything so that I can reach that?

Or do I need to do my own vertexcontroller to do so?
If so, is there any examples out there that could help me out?
Is that as fast as using animation? will it work for compiled objects using object.compiled(true)?

42
Support / Animation Interpolation Between Sequences
« on: November 06, 2019, 08:12:20 pm »
Just as the topic subject says, is it possible to add this in a near future? or is there a way to do it currently?

Regards

43
Support / Re: Low performance when using uncompiled objects
« on: November 04, 2019, 06:27:19 pm »
Many thanks for your time!

44
Support / Re: Low performance when using uncompiled objects
« on: November 02, 2019, 06:24:26 am »
I've done some tests, and it seems that it could be something like what you said.
Every time a new object comes into play and becomes visible inside the camera frustum, a new line of log will appear with the next content followed by some dragging and freezing of the simulation:

   Object 'object1579' shares compiled data with object 'object15'

and the simulation keeps running fine afterwards, until new objects are created in front of the camera while writing more of these lines to the console.

45
Support / Re: Acessing vertex color throught GLSL
« on: November 02, 2019, 12:57:35 am »
Great! many thanks

Pages: 1 2 [3] 4 5