[Kicad-developers] Very inefficient loading of 3D models

2014-08-02 Thread Andrew Zonenberg
So I added a few print statements to my copy of the 3D viewer in order to figure out why the 3D viewer was so slow... The results were very interesting. http://pastebin.com/7s8gXVjY 1) There is no caching whatsoever! The VRML/X3D files are loaded from scratch each time they're instantiated in th

Re: [Kicad-developers] Very inefficient loading of 3D models

2014-08-02 Thread Mário Luzeiro
ersteak.com] Sent: 02 August 2014 19:30 To: kicad-developers@lists.launchpad.net Subject: [Kicad-developers] Very inefficient loading of 3D models So I added a few print statements to my copy of the 3D viewer in order to figure out why the 3D viewer was so slow... The results were very interesting.

Re: [Kicad-developers] Very inefficient loading of 3D models

2014-08-02 Thread Andrew Zonenberg
_ > From: Kicad-developers > [kicad-developers-bounces+mrluzeiro=ua...@lists.launchpad.net] on behalf of > Andrew Zonenberg [azonenb...@drawersteak.com] > Sent: 02 August 2014 19:30 > To: kicad-developers@lists.launchpad.net > Subject: [Kicad-developers] Very inefficient loading of

Re: [Kicad-developers] Very inefficient loading of 3D models

2014-08-02 Thread Andrew Zonenberg
se I will soon start using kicad again as a user and will need > > to load beautiful 3d models.. and faster :) so it would be nice to have > > this optimized feature! > > > > > > From: Kicad-developers > > [kicad-

Re: [Kicad-developers] Very inefficient loading of 3D models

2014-08-02 Thread Mário Luzeiro
Zonenberg [azonenb...@drawersteak.com] Sent: 02 August 2014 20:14 To: Mário Luzeiro Cc: kicad-developers@lists.launchpad.net Subject: Re: [Kicad-developers] Very inefficient loading of 3D models I think one of the easiest optimizations is to add some kind of application-wide cache in RAM such that

Re: [Kicad-developers] Very inefficient loading of 3D models

2014-08-02 Thread Tomasz Wlostowski
On 02.08.2014 20:30, Andrew Zonenberg wrote: The attached patch parallelizes per-vertex normal calculation using OpenMP. I see a nearly 4x speedup of model loading on my quad-core machine. Hi Andrew, Caching the meshes including normals on disk could speed up loading even further: - take the

Re: [Kicad-developers] Very inefficient loading of 3D models

2014-08-02 Thread Andrew Zonenberg
Good idea. Let me work on getting a RAM cache working first, then we can update the "load file from disk" code later on. On Sat, 2014-08-02 at 21:35 +0200, Tomasz Wlostowski wrote: > On 02.08.2014 20:30, Andrew Zonenberg wrote: > > The attached patch parallelizes per-vertex normal calculation usi