Blue Brain BioExplorer
ArchiveLoader.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2018 EPFL/Blue Brain Project
3  * All rights reserved. Do not distribute without permission.
4  * Responsible Author: Jonas Karlsson <jonas.karlsson@epfl.ch>
5  *
6  * This file is part of Blue Brain BioExplorer <https://github.com/BlueBrain/BioExplorer>
7  *
8  * This library is free software; you can redistribute it and/or modify it under
9  * the terms of the GNU Lesser General Public License version 3.0 as published
10  * by the Free Software Foundation.
11  *
12  * This library is distributed in the hope that it will be useful, but WITHOUT
13  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
14  * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
15  * details.
16  *
17  * You should have received a copy of the GNU Lesser General Public License
18  * along with this library; if not, write to the Free Software Foundation, Inc.,
19  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
20  */
21 
22 #pragma once
23 
26 
27 #include <set>
28 
29 namespace core
30 {
31 class ArchiveLoader : public Loader
32 {
33 public:
34  ArchiveLoader(Scene& scene, LoaderRegistry& registry);
35 
36  std::vector<std::string> getSupportedStorage() const final;
37  std::string getName() const final;
38 
39  bool isSupported(const std::string& storage, const std::string& extension) const final;
40  ModelDescriptorPtr importFromBlob(Blob&& blob, const LoaderProgress& callback,
41  const PropertyMap& properties) const final;
42 
43  ModelDescriptorPtr importFromStorage(const std::string& storage, const LoaderProgress& callback,
44  const PropertyMap& properties) const final;
45 
46 private:
47  ModelDescriptorPtr loadExtracted(const std::string& path, const LoaderProgress& callback,
48  const PropertyMap& properties) const;
49  LoaderRegistry& _registry;
50 };
51 } // namespace core
ModelDescriptorPtr importFromStorage(const std::string &storage, const LoaderProgress &callback, const PropertyMap &properties) const final
ArchiveLoader(Scene &scene, LoaderRegistry &registry)
ModelDescriptorPtr importFromBlob(Blob &&blob, const LoaderProgress &callback, const PropertyMap &properties) const final
bool isSupported(const std::string &storage, const std::string &extension) const final
std::string getName() const final
std::vector< std::string > getSupportedStorage() const final
Scene object This object contains collections of geometries, materials and light sources that are use...
Definition: Scene.h:43
std::shared_ptr< ModelDescriptor > ModelDescriptorPtr
Definition: Types.h:112