HomeWildfire Games

Adds AsFloatArray to CMatrix3D.

Description

Adds AsFloatArray to CMatrix3D.

Event Timeline

Stan added a subscriber: Stan.Apr 28 2022, 6:48 PM
Stan added inline comments.
/ps/trunk/source/renderer/backend/gl/ShaderProgram.cpp
779

Weird to name a matrix v, shouldn't it be m ?

vladislavbelov marked an inline comment as done.Apr 28 2022, 8:09 PM
vladislavbelov added inline comments.
/ps/trunk/source/renderer/backend/gl/ShaderProgram.cpp
779

I suppose it was just copy-pasted from other methods. Anyway it'll be removed in the next patch.

phosit added a subscriber: phosit.Apr 29 2022, 9:52 AM

Why are so many CMatrix3D fonctions defined in the header?

/ps/trunk/source/maths/Matrix3D.h
326

information about the size is lost e.g. return const std::array<float,16>&

Why are so many CMatrix3D fonctions defined in the header?

Helping inline for compilers without LTO.

/ps/trunk/source/maths/Matrix3D.h
326

information about the size is lost e.g. return const std::array<float,16>&

std::array isn't a proper container here. I'll add PS::span in the next patch.

Helping inline for compilers without LTO.

Which is to say -> making those functions inlinable (in turn, allowing cascading optimisations), since we don't use LTO on any official compilation pipeline.

since we don't use LTO on any official compilation pipeline.

It'd be good to have LTO for release builds (if we don't use it yet there).

Stan added a comment.Apr 29 2022, 10:54 AM

You need to check all the compilers first.

In rP26834#57657, @Stan wrote:

You need to check all the compilers first.

I'd start from enabling LTO (LGTC) for MSVC, should be easy to check without side effects.