physis/layer/
common.rs

1// SPDX-FileCopyrightText: 2025 Joshua Goins <josh@redstrate.com>
2// SPDX-License-Identifier: GPL-3.0-or-later
3
4use binrw::binrw;
5
6#[binrw]
7#[derive(Debug)]
8#[brw(little)]
9pub struct RelativePositions {
10    pos: i32,
11    pos_count: i32,
12}
13
14#[binrw]
15#[derive(Debug)]
16#[brw(little)]
17#[allow(dead_code)] // most of the fields are unused at the moment
18pub struct Transformation {
19    pub translation: [f32; 3],
20    pub rotation: [f32; 3],
21    pub scale: [f32; 3],
22}
23
24#[binrw]
25#[derive(Debug)]
26#[brw(little)]
27pub struct Color {
28    pub red: u8,
29    pub green: u8,
30    pub blue: u8,
31    pub alpha: u8,
32}
33
34#[binrw]
35#[derive(Debug)]
36#[brw(little)]
37pub struct ColorHDRI {
38    pub red: u8,
39    pub green: u8,
40    pub blue: u8,
41    pub alpha: u8,
42    pub intensity: f32,
43}