Files
test2/source/blender/io/stl/IO_stl.hh
Campbell Barton 381898b6dc Refactor: move BLI_path_util header to C++, rename to BLI_path_utils
Move to a C++ header to allow C++ features to be used there,
use the "utils" suffix as it's preferred for new files.

Ref !128147
2024-09-26 21:13:39 +10:00

54 lines
1.1 KiB
C++

/* SPDX-FileCopyrightText: 2023 Blender Authors
*
* SPDX-License-Identifier: GPL-2.0-or-later */
/** \file
* \ingroup stl
*/
#pragma once
#include "BLI_path_utils.hh"
#include "DNA_ID.h"
#include "IO_orientation.hh"
struct Mesh;
struct bContext;
struct ReportList;
struct STLImportParams {
/** Full path to the source STL file to import. */
char filepath[FILE_MAX];
eIOAxis forward_axis;
eIOAxis up_axis;
bool use_facet_normal;
bool use_scene_unit;
float global_scale;
bool use_mesh_validate;
ReportList *reports = nullptr;
};
struct STLExportParams {
/** Full path to the to-be-saved STL file. */
char filepath[FILE_MAX];
eIOAxis forward_axis;
eIOAxis up_axis;
float global_scale;
bool export_selected_objects;
bool use_scene_unit;
bool apply_modifiers;
bool ascii_format;
bool use_batch;
char collection[MAX_IDPROP_NAME] = "";
ReportList *reports = nullptr;
};
void STL_import(bContext *C, const STLImportParams *import_params);
void STL_export(bContext *C, const STLExportParams *export_params);
Mesh *STL_import_mesh(const STLImportParams *import_params);