Overte C++ Documentation
BakerLibrary.h
1 //
2 // ModelBaker.h
3 // libraries/baking/src/baking
4 //
5 // Created by Sabrina Shanman on 2019/02/14.
6 // Copyright 2019 High Fidelity, Inc.
7 //
8 // Distributed under the Apache License, Version 2.0.
9 // See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
10 //
11 
12 #ifndef hifi_BakerLibrary_h
13 #define hifi_BakerLibrary_h
14 
15 #include <QUrl>
16 
17 #include "../ModelBaker.h"
18 
19 // Returns either the given model URL if valid, or an empty URL
20 QUrl getBakeableModelURL(const QUrl& url);
21 
22 bool isModelBaked(const QUrl& bakeableModelURL);
23 
24 // Assuming the URL is valid, gets the appropriate baker for the given URL, and creates the base directory where the baker's output will later be stored
25 // Returns an empty pointer if a baker could not be created
26 std::unique_ptr<ModelBaker> getModelBaker(const QUrl& bakeableModelURL, const QString& contentOutputPath);
27 
28 // Similar to getModelBaker, but gives control over where the output folders will be
29 std::unique_ptr<ModelBaker> getModelBakerWithOutputDirectories(const QUrl& bakeableModelURL, const QString& bakedOutputDirectory, const QString& originalOutputDirectory);
30 
31 #endif // hifi_BakerLibrary_h