Hi HP,
I was able to display 2 different RGBComposites in the same panel:
Formulas -> Three Color (RGB) Image (Auto-scale)
Using version 1.7beta1, build date 2018-01-03
looking for correct data type in RGB script
Re: looking for correct data type in RGB script
Hi Tom -
Here's a script that shows the problem in today's nightly:
After the first RGB display is created, McV locks up. If you change "combineRGB" to "mycombineRGB" then things work as expected in this script. It's the "Three Color (RGB) Image" formula that's the problem.
- Bob
Here's a script that shows the problem in today's nightly:
Code: Select all
addeParms = dict(
server = 'msg.ssec.wisc.edu',
dataset = 'MSG',
descriptor = 'FD',
time = '12:00:00',
size = 'ALL',
)
b1 = loadADDEImage(band=1, **addeParms)
b2 = loadADDEImage(band=2, **addeParms)
b3 = loadADDEImage(band=3, **addeParms)
b4 = loadADDEImage(band=4, **addeParms)
rgb1 = combineRGB(b3, b2, b1)
rgb2 = combineRGB(b4, b1, b2)
layer1 = activeDisplay().createLayer('RGB Composite', rgb1)
layer2 = activeDisplay().createLayer('RGB Composite', rgb2)
After the first RGB display is created, McV locks up. If you change "combineRGB" to "mycombineRGB" then things work as expected in this script. It's the "Three Color (RGB) Image" formula that's the problem.
- Bob
Re: looking for correct data type in RGB script
I would replace combineRGB with mycombineRGB, and then remove mycombineRGB. I'm not
sure of the threading model used in the scripting, so the lock up could very well be related
to adding the second RGB (this script would probably be fine if you take out the 2nd composite)
sure of the threading model used in the scripting, so the lock up could very well be related
to adding the second RGB (this script would probably be fine if you take out the 2nd composite)
Re: looking for correct data type in RGB script
The are a couple relevant inquiries related to these RGB formulas:
Inquiry 2282: Passing a list of RGB images (created with combineRGB or mycombineRGB) into createLayer does not result in a loop.
Inquiry 2283: Investigate the need of having two formulas to create RGB displays.
One problem with just swapping out combineRGB with mycombineRGB is that, as seen in the 02 Mar 2016, 19:27 post in this thread, is that you can create a loop by using ImageSequenceImpl with combineRGB. However, this ImageSequenceImpl method doesn't allow for creating loops with mycombineRGB.
I agree that it would be optimal to have only one RGB formula.
- Bob
Inquiry 2282: Passing a list of RGB images (created with combineRGB or mycombineRGB) into createLayer does not result in a loop.
Inquiry 2283: Investigate the need of having two formulas to create RGB displays.
One problem with just swapping out combineRGB with mycombineRGB is that, as seen in the 02 Mar 2016, 19:27 post in this thread, is that you can create a loop by using ImageSequenceImpl with combineRGB. However, this ImageSequenceImpl method doesn't allow for creating loops with mycombineRGB.
I agree that it would be optimal to have only one RGB formula.
- Bob
Re: looking for correct data type in RGB script
It appears there is a slight confused with formula 'Three Color (RGB) Image (Auto-scale)' and display type '3 Color (RGB) Image'. What I am speaking about (and have a problem with) is the display type. As Bob correctly states in his code a couple of emails above
is that display type 'RGB Composite' blocks up McV. When replacing it with '3 Color (RGB) Image' like
the code runs smoothly its end.
And here again I state my problem with '3 Color (RGB) Image'. It gives no access to range and gamma settings of the 3 beams, which on the other hand 'RGB Composite' does. I definitely would like to see an RGB display type that does not block McV and has the range/gamma setting features of 'RGB Composite'. Also, it would be convenient to streamline the RGB-creating methods '(my)combineRGB()'.
HP
Code: Select all
layer1 = activeDisplay().createLayer('RGB Composite', rgb1)
is that display type 'RGB Composite' blocks up McV. When replacing it with '3 Color (RGB) Image' like
Code: Select all
layer1 = activeDisplay().createLayer('3 Color (RGB) Image', rgb1)
the code runs smoothly its end.
And here again I state my problem with '3 Color (RGB) Image'. It gives no access to range and gamma settings of the 3 beams, which on the other hand 'RGB Composite' does. I definitely would like to see an RGB display type that does not block McV and has the range/gamma setting features of 'RGB Composite'. Also, it would be convenient to streamline the RGB-creating methods '(my)combineRGB()'.
HP
Re: looking for correct data type in RGB script
Just replace combineRGB with mycombineRGB and both Display Types will work. Use the script above to
verify: you can use 'RGB Composite' or '3 Color (RGB) Image' if you always use mycombineRGB.
So like I said in my previous post just replace the contents of combineRGB with mycombineRGB and
remove the latter.
verify: you can use 'RGB Composite' or '3 Color (RGB) Image' if you always use mycombineRGB.
So like I said in my previous post just replace the contents of combineRGB with mycombineRGB and
remove the latter.
Re: looking for correct data type in RGB script
I agree with Tom that with mycombine RGB() both Display Types work, but only if you produce a single RGB image. If you run send an RGB time sequence to mycombine, she quits with the error message:
This problem has already been documented (maybe in fuzzy way) further up in this thread and in Inq #2282.
HP
visad.TypeException: FieldImpl.setSample: bad range type
This problem has already been documented (maybe in fuzzy way) further up in this thread and in Inq #2282.
HP
Re: looking for correct data type in RGB script
Hi HP, Bob,
I think this one we can fix.
Tom
I think this one we can fix.
Tom
Re: looking for correct data type in RGB script
Hi Tom & Bob -
Please tell me if it will be fixed (soon). If yes, tell me please.
HP
Please tell me if it will be fixed (soon). If yes, tell me please.
HP