Files
test2/source/blender/io/stl/IO_stl.cc
Aras Pranckevicius 17c793e43c IO: C++ STL exporter
There was a C++ STL importer since Blender 3.3, but no corresponding C++ STL exporter. This PR is adding said exporter: taking https://projects.blender.org/blender/blender/pulls/105598 and finishing it (agreed with original author).

Exporting Suzanne with 6 level subdivision (4 million triangles), on Apple M1 Max:
- Binary: python exporter 7.8 sec -> C++ exporter 0.9 sec.
- Ascii: python exporter 13.1 sec -> C++ exporter 4.5 sec.

Co-authored-by: Iyad Ahmed <iyadahmed430@gmail.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/114862
2023-11-19 16:41:20 +01:00

26 lines
540 B
C++

/* SPDX-FileCopyrightText: 2023 Blender Authors
*
* SPDX-License-Identifier: GPL-2.0-or-later */
/** \file
* \ingroup stl
*/
#include "BLI_timeit.hh"
#include "IO_stl.hh"
#include "stl_export.hh"
#include "stl_import.hh"
void STL_import(bContext *C, const STLImportParams *import_params)
{
SCOPED_TIMER("STL Import");
blender::io::stl::importer_main(C, *import_params);
}
void STL_export(bContext *C, const STLExportParams *export_params)
{
SCOPED_TIMER("STL Export");
blender::io::stl::exporter_main(C, *export_params);
}