MATRIXCOMPMULT(3G)
π MATRIXCOMPMULT π
okay bestie, gather round, because we're about to talk about matrixCompMult from the 3G manual section, and it's genuinely so much simpler than it sounds. no cap. π¦
β¨ NAME β¨
matrixCompMult β do a component-wise multiplication of two matrices. that's it. that's the whole vibe. π
πΈ DECLARATION πΈ
here's the tea, exactly as written:
mat matrixCompMult(mat x, mat y);
dmat matrixCompMult(dmat x, dmat y);
two flavors, two moods, same energy. π
π«Ά PARAMETERS π«Ά
xβ the first matrix multiplicand. yeah she's the first one up. πyβ the second matrix multiplicand. and she's the second. iconic duo fr fr.
π DESCRIPTION π
so matrixCompMult performs a component-wise multiplication of two matrices, and what you get back is a result matrix where every single component, result[i][j], is computed as the scalar product of x[i][j] and y[i][j].
likeβ¦ it's not the fancy matrix-times-matrix thing you might be picturing, bestie. it's element by element. position by position. x[i][j] times y[i][j], slotted right into result[i][j]. literally just that. and honestly? she ate. β¨
π VERSION SUPPORT π
bestie the original had a whole big grid here, so let me translate it into a format your eyeballs can actually survive. every β-free row, every version, all of it. no skipping. π
matrixCompMult (genType) β supported in every single one of these, she's been here since day one:
- OpenGL Shading Language Version
1.10β β - OpenGL Shading Language Version
1.20β β - OpenGL Shading Language Version
1.30β β - OpenGL Shading Language Version
1.40β β - OpenGL Shading Language Version
1.50β β - OpenGL Shading Language Version
3.30β β - OpenGL Shading Language Version
4.00β β - OpenGL Shading Language Version
4.10β β - OpenGL Shading Language Version
4.20β β - OpenGL Shading Language Version
4.30β β - OpenGL Shading Language Version
4.40β β - OpenGL Shading Language Version
4.50β β
matrixCompMult (genDType) β the double-precision girlie showed up fashionably late, but she's been thriving ever since:
- OpenGL Shading Language Version
1.10β - - OpenGL Shading Language Version
1.20β - - OpenGL Shading Language Version
1.30β - - OpenGL Shading Language Version
1.40β - - OpenGL Shading Language Version
1.50β - - OpenGL Shading Language Version
3.30β - - OpenGL Shading Language Version
4.00β β - OpenGL Shading Language Version
4.10β β - OpenGL Shading Language Version
4.20β β - OpenGL Shading Language Version
4.30β β - OpenGL Shading Language Version
4.40β β - OpenGL Shading Language Version
4.50β β
so basically: genType = always been there, genDType = 4.00 and onward only. iykyk. π
π¦ SEE ALSO π¦
dot()reflect()
go read those too, they're lowkey a vibe. π
π COPYRIGHT π
Copyright Β© 2011-2014 Khronos Group. This material may be distributed subject to the terms and conditions set forth in the Open Publication License, v 1.0, 8 June 1999. http://opencontent.org/openpub/.
π COPYRIGHT (again, yes really) π
Copyright Β© 2011-2014 Khronos Group
and that's a wrap bestie!! π this page came to you from [FIXME: source], dated 01/03/2018, and it lives in the 3G manual section β mwah, kisses, go multiply some matrix components component-wise πβ¨
π¦ where this page comes from
- ubuntu jammy: opengl-4-man-doc 1.0~svn33624-1 Β· SGI-Free-Software-B-License-2
- ubuntu noble: opengl-4-man-doc 1.0~svn33624-1 Β· SGI-Free-Software-B-License-2
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms