Jump to content

  • Log In with Google      Sign In   
  • Create Account


DX11 - Sponza Scene - Comparison of loading times


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
13 replies to this topic

#1 Migi0027   Crossbones+   -  Reputation: 1631

Like
0Likes
Like

Posted 13 September 2013 - 08:59 AM

Hi guys! wink.png

 

Well I decided to look into the topic of global illumination, and as seen, many of those demos use the Sponza Scene (From Crytek), because of its complexity. And, well, I tried it as well, but my loading time seems quite high just for the Sponza Scene. (Loading the file, creating buffers, and creating a simple texture material).

 

Loading time for my project: 21.9 Seconds (21 for Loading the actual file, ~1 for Creating the buffers) wacko.png

 

For those people who have tried loading this scene before, what are your loading times, are mine terrible?

 

Thanks, as usual.

-MIGI0027


Hi! Cuboid Zone
The Rule: Be polite, be professional, but have a plan to kill everyone you meet, ohh, AND STEAL ALL ZE TRIANGLES FROM ZHEM!

Sponsor:

#2 mhagain   Crossbones+   -  Reputation: 7833

Like
0Likes
Like

Posted 13 September 2013 - 10:50 AM

What format are you trying to load it in?  Sounds like you might be parsing text, which is never going to be fast; instead you should preprocess the model into a binary format that can be just loaded directly into buffers with a single fread.


It appears that the gentleman thought C++ was extremely difficult and he was overjoyed that the machine was absorbing it; he understood that good C++ is difficult but the best C++ is well-nigh unintelligible.


#3 Migi0027   Crossbones+   -  Reputation: 1631

Like
0Likes
Like

Posted 13 September 2013 - 11:03 AM

Well, the thing is that I use Assimp. dry.png


Hi! Cuboid Zone
The Rule: Be polite, be professional, but have a plan to kill everyone you meet, ohh, AND STEAL ALL ZE TRIANGLES FROM ZHEM!

#4 Yourself   Crossbones+   -  Reputation: 1117

Like
0Likes
Like

Posted 13 September 2013 - 12:06 PM

My framework loads the crytek sponza in about 2-3 seconds, though preprocessing ( geometry to binary data, textures to dds, compiling hlsl... ) takes about 15-20 seconds.

#5 DwarvesH   Members   -  Reputation: 459

Like
0Likes
Like

Posted 13 September 2013 - 01:10 PM

Wow, too much. Give me link to the sponza scene and I'll test it. I can load now a few MiB of meshes and about 300 MiB of textures in DDS format in 3-4 seconds.



#6 imoogiBG   Members   -  Reputation: 1133

Like
0Likes
Like

Posted 13 September 2013 - 01:17 PM

3 seconds to load ONLY the geometry (from a text file).



#7 Migi0027   Crossbones+   -  Reputation: 1631

Like
0Likes
Like

Posted 13 September 2013 - 01:25 PM

PS. When I mean the load time, I mean:

  • Loading the file (Assimp)
  • Parsing it (Assimp)
  • Triangulating (Assimp)
  • Copying Vertices / Normals / Tangent...
  • Calculating bounding box
  • Create shader/material
  • Create ALL textures.
  • Create buffers (v/i)

Hi! Cuboid Zone
The Rule: Be polite, be professional, but have a plan to kill everyone you meet, ohh, AND STEAL ALL ZE TRIANGLES FROM ZHEM!

#8 Migi0027   Crossbones+   -  Reputation: 1631

Like
0Likes
Like

Posted 13 September 2013 - 01:28 PM

DwarvesH: http://www.crytek.com/cryengine/cryengine3/downloads


Hi! Cuboid Zone
The Rule: Be polite, be professional, but have a plan to kill everyone you meet, ohh, AND STEAL ALL ZE TRIANGLES FROM ZHEM!

#9 Jason Z   Crossbones+   -  Reputation: 4905

Like
0Likes
Like

Posted 13 September 2013 - 05:11 PM

Are you testing this in a debug or a release build?  File operations can be significantly slower in debug builds than release builds, so that might account for some of the time.  If that isn't the issue, you might want to profile each of the operations you listed above to see which one is taking the most time.  It doesn't need to be anything fancy, just dump the system time in milliseconds to the output debug area when each process finishes.  That should help you figure out what is going on.



#10 Migi0027   Crossbones+   -  Reputation: 1631

Like
0Likes
Like

Posted 14 September 2013 - 02:25 AM

Jason Z:

 

I'm using release build for this.

Thanks! I'm going to start profiling it in a while.


Hi! Cuboid Zone
The Rule: Be polite, be professional, but have a plan to kill everyone you meet, ohh, AND STEAL ALL ZE TRIANGLES FROM ZHEM!

#11 Hodgman   Moderators   -  Reputation: 29567

Like
1Likes
Like

Posted 14 September 2013 - 02:33 AM

What format are you trying to load it in?  Sounds like you might be parsing text, which is never going to be fast; instead you should preprocess the model into a binary format that can be just loaded directly into buffers with a single fread.

Well, the thing is that I use Assimp. dry.png

You can still take your code that uses Assimp and move it into an external tool that you run ahead of time, which you can then use generate a simpler binary file that can be loaded quickly.

#12 Migi0027   Crossbones+   -  Reputation: 1631

Like
0Likes
Like

Posted 14 September 2013 - 04:12 AM

 

 

What format are you trying to load it in?  Sounds like you might be parsing text, which is never going to be fast; instead you should preprocess the model into a binary format that can be just loaded directly into buffers with a single fread.

Well, the thing is that I use Assimp. dry.png

 

You can still take your code that uses Assimp and move it into an external tool that you run ahead of time, which you can then use generate a simpler binary file that can be loaded quickly.

 

 

Huh.. Don't know why I didn't think of that, but thanks, I'll give it a try.


Hi! Cuboid Zone
The Rule: Be polite, be professional, but have a plan to kill everyone you meet, ohh, AND STEAL ALL ZE TRIANGLES FROM ZHEM!

#13 DwarvesH   Members   -  Reputation: 459

Like
0Likes
Like

Posted 18 September 2013 - 02:30 AM

Sorry, I've been implementing terrain LOD and did not have time to profile my loading of the mesh. But when I do have time, this 22 MiB mesh will surely be interesting to load and render. I saw the sponza mesh everywhere. Pretty much anybody writing an engine has screenshots with it, but I never used it before. It will be a good stress test for my forward rendering of multiple point lights.



#14 Migi0027   Crossbones+   -  Reputation: 1631

Like
0Likes
Like

Posted 18 September 2013 - 02:53 AM

Btw.

 

When I said creating all textures, I mean the diffuse, normals and specular.


Hi! Cuboid Zone
The Rule: Be polite, be professional, but have a plan to kill everyone you meet, ohh, AND STEAL ALL ZE TRIANGLES FROM ZHEM!




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS