[Bf-committers] Blender 2.8 gpu matrix API design questions

Dalai Felinto dfelinto at gmail.com
Fri Apr 14 11:46:20 CEST 2017


Hi,

Blender 2.8 Matrix API [1] implementation makes a distinction between
the 3D and 2D matrices, diverging from the classic OpenGL single stack
implementation.

I had Sergey help me going over the available related documents
[2][3], as well as the code itself [1]. And we have the following
questions.

1) Why to separate 2D and 3D matrices stacks?

2) Was this decision discussed anywhere?

I see this first mentioned in the bf-viewport thread about "OpenGL low
level shader API proposal" [4]. But there is only one related reply
that actually argues against this [5].

3) CPU performance can be improved by vectorization (such as SSE)

We already enforce SSE2 support for Blender hardware. In that sense,
3x3 operations will be less efficient than 4x4 operations (on the CPU
side).

4) Future "unproof" design

There are a few areas of future Blender features that make little
distinction between 2D and 3D spaces. For example custom manipulators
and VR interface.

[1] https://developer.blender.org/diffusion/B/browse/blender2.8/source/blender/gpu/intern/gpu_matrix.c
[2] https://wiki.blender.org/index.php/Dev:2.8/Source/OpenGL/Transformations
[3] https://docs.google.com/document/d/17xF5urqTkOZQYlXcgXMJURcI2pxt_qiwZdlLxoTG2oU/edit
[4] https://lists.blender.org/pipermail/bf-viewport/2015-December/000052.html
[5] https://lists.blender.org/pipermail/bf-viewport/2015-December/000049.html

Regards,
Dalai
--
blendernetwork.org/dalai-felinto
www.dalaifelinto.com


More information about the Bf-committers mailing list