Fix potential thread violation in applying gainmaps

When deciding whether or not to apply the gainmap & if so by how much
only use the CanvasContext ratio if we are on RenderThread.

Bug: 293927383
Test: Good guess
Change-Id: Ie49ae2718df09ab14019b354197d99538e8c6b04
1 file changed