Skip to content

Commit

Permalink
fix build
Browse files Browse the repository at this point in the history
  • Loading branch information
Mike-Leo-Smith committed Dec 29, 2022
1 parent 1e1f27e commit 19a543b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/util/half.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,17 @@
// Created by Mike Smith on 2022/11/18.
//

#include <bit>

#include <core/stl.h>
#include <util/half.h>

namespace luisa::render {

// from tinyexr: https://github.com/syoyo/tinyexr/blob/master/tinyexr.h
float half_to_float(uint h) noexcept {
static_assert(std::endian::native == std::endian::little,
"Only little endian is supported");
union FP32 {
uint u;
float f;
Expand Down

0 comments on commit 19a543b

Please sign in to comment.