Standard default Qt3D and attributes

I started to learn how to use shaders with QML, and I can’t find any links that talk about uniform default values ​​and attribute values ​​that are passed to the shaders. In some examples, we can see that some of them are similar to vertexPosition or modelViewProjection (which are also passed as mvp ), but there is no clear list containing all the variables that we can use.

After examining the Qt source code, I recognized the default name for many variables:

  • uniform variables (found in renderview.cpp)
    • modelMatrix
    • viewMatrix
    • projectionMatrix
    • species
    • viewProjectionMatrix
    • modelViewProjection
    • MVP
    • inverseModelMatrix
    • inverseViewMatrix
    • inverseProjectionMatrix
    • inverseModelView
    • inverseViewProjectionMatrix
    • inverseModelViewProjection
    • modelNormalMatrix
    • modelViewNormal
    • viewportMatrix
    • inverseViewportMatrix
    • eyePosition
  • ( qattribute.cpp)
    • vertexPosition
    • vertexNormal
    • vertexColor
    • vertexTexCoord
    • vertexTangent

? , , , -.

+4

Source: https://habr.com/ru/post/1684358/


All Articles