Hi HP -
That's good to know that this was not a problem in McV 1.4. I went back and verified that this is true and I added this information to the inquiry. I did a side-by-side diff of the bundle files and there are many differences between a bundle created in McV 1.4 and McV 1.7beta1, but nothing is jumping out at me either as to why things would be working differently in the nightly.
For now, I did find one workaround that may work for you. After loading the bundle in the nightly, you can use the Jython Shell to get a reference to each data object displayed and then you can perform mathematical operations on those data objects. Here is what you can do:
- Load your bundle as you normally would.
- Open the Jython Shell and get a reference to the first imagery layer displayed:
Code:
sat_layer_1 = activeDisplay().getLayer(1)
# getLayer() grabs a reference to a displayed layer. The number is the index number of the layer
# in the display which is 0-based. Layer 0 would be the first layer displayed (likely the map) and 1
# would be the first real layer of data displayed. This is going to be the bottom imagery layer in
# the Legend. You can verify you got the correct layer by running:
# sat_layer_1.setLayerVisible(False)
# You can re-run this with "True" to turn the visibility back on.
- Now that we have a reference to the layer, we need a reference to the actual data. Run:
Code:
sat_data_1 = sat_layer_1.getData()
- We also need a reference to the other data object. Run:
Code:
sat_data_2 = activeDisplay().getLayer(2).getData()
- Now you can subtract the layers with:
Code:
sat_sub = sub(sat_data_1, sat_data_2)
- Finally, display the subtracted data with:
Code:
sub_layer = activeDisplay().createLayer("Image Display",sat_sub)
If you give this a try and have any problems or thoughts on it, please let me know.
Thanks -
Bob