From 5e5b2e4071e5d54463717e0a8791c93d692c813c Mon Sep 17 00:00:00 2001 From: Christopher Snowhill Date: Fri, 27 May 2022 04:33:07 -0700 Subject: [PATCH] [Visualization] Add micro bias to cylinder scale Apparently, old macOS wants to divide something by the scale size, so setting it to zero causes division by zero errors? Let's set it to a really small number instead. Signed-off-by: Christopher Snowhill --- Visualization/SpectrumView.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Visualization/SpectrumView.m b/Visualization/SpectrumView.m index 6f224f4a9..a721e0de9 100644 --- a/Visualization/SpectrumView.m +++ b/Visualization/SpectrumView.m @@ -345,7 +345,7 @@ extern NSString *CogPlaybackDidStopNotficiation; SCNNode *dotNode = nodes[i + 1 + 11]; SCNVector3 position = node.position; position.y = maxValue * 0.5; - node.scale = SCNVector3Make(1.0, maxValue, 1.0); + node.scale = SCNVector3Make(1.0, maxValue + 1e-7, 1.0); node.position = position; position = dotNode.position;