Fix infinite loop in the OITs rhiCalculateABufferSize function


With a negative input (node count) the loop would loop forever, as the
exit condition was never met (the value would always wrap). Replaced
the loop with a simple sqrt and ceil combination.
Also added the oitNodeCount member to the member initialization list to
avoid garbage numbers being used. Default oitNodeCount is set to 0.

Task-number: QTBUG-149055
Pick-to: 6.12 6.11
Change-Id: Ie13a3f9a664543f44fac58b7beb8663e0c02ccfc
Reviewed-by: Jonas Karlsson <jonas.karlsson@qt.io>
Reviewed-by: Antti Määttä <antti.maatta@qt.io>
commitafb92c6f2461eaa05e55fbf608c15b4dbf663c1f
parent5d75c5eadaa7fc60bb0965b8c3276e4a69615dc2
authorChristian Strømme <christian.stromme@qt.io>
committerChristian Strømme <christian.stromme@qt.io>
commit timeMon, 24 Aug 2026 19:03:06 +0000