On Thu, Jun 24, 2010 at 10:57 AM, Thomas Paviot <tpav...@gmail.com> wrote:
> 2010/6/24 Thiago Franco Moraes <totonixs...@gmail.com>
>>
>> On Thu, Jun 24, 2010 at 10:27 AM, Thomas Paviot <tpav...@gmail.com> wrote:
>> > Hi Thiago,
>> > I also noticed a strong memory consumption and cpu usage with big STL
>> > files
>> > (1e6 faces is actually a *huge* number of faces).
>> > The thing is : why do you want to load these STL files? If it is only
>> > for
>> > visualization, may be OCC/pythonOCC is not the best tool for that need
>> > (you
>> > talk about MeshLab, which I don't know).
>> > Now, if you want to do 3D modeling over your STL file (like add a
>> > chamfer on
>> > an edge, drill a hole, slice the shape for manufacturing etc.) then you
>> > *need* a 3D modeling library and pythonOCC can help you. But, in that
>> > case,
>> > the STL file needs to be mapped to the OCC internal data model
>> > (TopoDS_Shapes, *Edges, Vertices*) and that's why the loading requires
>> > so
>> > much memory/cpu usage. So I don't know if you face a bug : OCC should be
>> > compared to another modeling tool, and that's a benchmark I didn't make.
>> > Best Regards,
>> > Thomas
>>
>> Hi Thomas,
>>
>> I'm developing a open source medical software named InVesalius [1],
>> from medical exams (CT, RMI) it generates STL to be used in 3D
>> printers to print phisical models that doctors and odontologists can
>> use to plan a surgery. Our software is developed using VTK [2]. Now
>> our objective is to convert that STLs to STEP to use in CAD softwares.
>>
>> Thanks!
>>
>> [1] - http://svn.softwarepublico.gov.br/trac/invesalius
>> [2] - http://www.vtk.org/
>
> Conversion from CAD to STL, then STL to STEP and back to CAD is a strange
> workflow. The STEP file generated from the STL mesh will be huge and any CAD
> program will fail loading it (well, that's an assumption, didn't test).
> Furthermore, the conversion from a mesh to a BRep geometry is still an open
> issue.
> According to me, a better way is to generate the STEP and STL files from the
> same CAD program. VTK does not handle STEP files and, in a sense, it can be
> easily understood : the "V" of VTK stands for "Visualization", whereas STEP
> is rather related to modeling. I think that both OCC and VTK should be used
> in a complete modeling/visualization application. The salome development
> team (http://www.salome-platform.org) recently commited a code named
> 'OCC2VTK'. It's not released yet, but it could be very interesting to have
> both libraries interoperable.
> Best Regards,
> Thomas

Thanks Thomas, I'll take a look in OCC2VTK. I've just uploaded a STL
file here http://ubuntuone.com/p/7uN/ , if someone wants to test.

>>
>>
>> > 2010/6/24 Thiago Franco Moraes <totonixs...@gmail.com>
>> >>
>> >> Hi all,
>> >>
>> >> I've been trying to read STL files. With small STL files it reads
>> >> normally. With not so big STL files (like the one I've just tried to
>> >> read that have 51 MB, binary, 534678 vertices, 1069782 faces) it can't
>> >> read, the CPU usage is about 100% and memory grows up from a few MB to
>> >> 4 GB then I have to kill my script. Using Meshlab the memory usage is
>> >> about 270 MB. I've tried to use STLImporter class and StlAPI class.
>> >> Bellow the code I used:
>> >>
>> >> from OCC.Utils.DataExchange import STL
>> >> reader = STL.STLImporter('file.stl')
>> >> reader.ReadFile()
>> >>
>> >> Ah, I'm using the packages from Ubuntu 10.04 64 bits, the last version
>> >> in PPA repository [1].
>> >>
>> >> I have done something wrong on trying to read that file? Is it a bug?
>> >> If necessary I can upload the STL in some place.
>> >>
>> >> Thanks!
>> >>
>> >> [1] - https://launchpad.net/~cae-team/+archive/ppa
>> >>
>> >> _______________________________________________
>> >> Pythonocc-users mailing list
>> >> Pythonocc-users@gna.org
>> >> https://mail.gna.org/listinfo/pythonocc-users
>> >
>> >
>> > _______________________________________________
>> > Pythonocc-users mailing list
>> > Pythonocc-users@gna.org
>> > https://mail.gna.org/listinfo/pythonocc-users
>> >
>> >
>>
>> _______________________________________________
>> Pythonocc-users mailing list
>> Pythonocc-users@gna.org
>> https://mail.gna.org/listinfo/pythonocc-users
>
>
> _______________________________________________
> Pythonocc-users mailing list
> Pythonocc-users@gna.org
> https://mail.gna.org/listinfo/pythonocc-users
>
>

_______________________________________________
Pythonocc-users mailing list
Pythonocc-users@gna.org
https://mail.gna.org/listinfo/pythonocc-users

Reply via email to