Blender V4.3
light.hh
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2011-2022 Blender Authors
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
4
5#pragma once
6
7#include <pxr/base/tf/hashmap.h>
8#include <pxr/usd/sdf/assetPath.h>
9#include <pxr/usd/sdf/path.h>
10
11#include "BKE_light.h"
12
13#include "object.hh"
14
15namespace blender::io::hydra {
16
17class InstancerData;
18
19class LightData : public ObjectData {
20 friend InstancerData;
21
22 protected:
23 std::map<pxr::TfToken, pxr::VtValue> data_;
24 pxr::TfToken prim_type_;
25
26 public:
27 LightData(HydraSceneDelegate *scene_delegate, const Object *object, pxr::SdfPath const &prim_id);
28
29 void init() override;
30 void insert() override;
31 void remove() override;
32 void update() override;
33
34 pxr::VtValue get_data(pxr::TfToken const &key) const override;
35
36 protected:
37 pxr::TfToken prim_type(const Light *light);
38};
39
40} // namespace blender::io::hydra
General operations, lookup, etc. for blender lights.
pxr::SdfPath prim_id
Definition id.hh:36
pxr::TfToken prim_type(const Light *light)
std::map< pxr::TfToken, pxr::VtValue > data_
Definition light.hh:23
pxr::VtValue get_data(pxr::TfToken const &key) const override