After seeing some examples online and the javadocs, I thought this is how I could adjust the brightness and contrast from a script in the BigDataViewer:
from bdv.util import BdvFunctions, Bdv
from bdv.tools import InitializeViewerState
bdv = BdvFunctions.show(cachedCellImg, "4D volume")
print bdv.getBdvHandle()
InitializeViewerState.initBrightness(16, 510, bdv.getBdvHandle().getBigDataViewer().getViewerFrame())
But when I run it, the BigDataViewer still shows the default brightness and contrast (the whole 16-bit range).
Am I missing something?
Thanks,
Albert