Blender V4.3
obj_exporter.hh
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2023 Blender Authors
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
4
9#pragma once
10
11#include "BLI_utility_mixins.hh"
12
13#include "BLI_vector.hh"
14
15#include "IO_wavefront_obj.hh"
16
17struct bContext;
18struct Collection;
19
20namespace blender::io::obj {
21
27 private:
28 Depsgraph *depsgraph_ = nullptr;
29 bool needs_free_ = false;
30
31 public:
32 OBJDepsgraph(const bContext *C, eEvaluationMode eval_mode, Collection *collection);
34
35 Depsgraph *get();
37};
38
48void exporter_main(bContext *C, const OBJExportParams &export_params);
49
50class OBJMesh;
51class OBJCurve;
52
64void export_frame(Depsgraph *depsgraph,
65 const OBJExportParams &export_params,
66 const char *filepath);
67
79std::pair<Vector<std::unique_ptr<OBJMesh>>, Vector<std::unique_ptr<OBJCurve>>>
80filter_supported_objects(Depsgraph *depsgraph, const OBJExportParams &export_params);
81
90bool append_frame_to_filename(const char *filepath,
91 int frame,
92 char r_filepath_with_frames[1024 /*FILE_MAX*/]);
93} // namespace blender::io::obj
eEvaluationMode
OBJDepsgraph(const bContext *C, eEvaluationMode eval_mode, Collection *collection)
const Depsgraph * depsgraph
bool append_frame_to_filename(const char *filepath, const int frame, char r_filepath_with_frames[1024])
std::pair< Vector< std::unique_ptr< OBJMesh > >, Vector< std::unique_ptr< OBJCurve > > > filter_supported_objects(Depsgraph *depsgraph, const OBJExportParams &export_params)
void exporter_main(bContext *C, const OBJExportParams &export_params)
void export_frame(Depsgraph *depsgraph, const OBJExportParams &export_params, const char *filepath)