Author Topic: ProcessContainer  (Read 3116 times)

Offline Alejandro Tombolini

  • PTeam Member
  • PixInsight Jedi
  • *****
  • Posts: 1267
    • Próxima Sur
ProcessContainer
« on: 2012 March 29 17:47:40 »
Hi.

I have an image with mask.
When applying MT (for example) over the image it works fine but if applying having adding the process previously to a Process Container doesn't work well, Mask is always considered as a direct mask, it doesn't take in consideration when mask is inverted.

_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._.

Hola,

Tengo una imagen con máscara.
Cuando le aplico MT (por ejemplo, o cualquier otro proceso) sobre la imagen funciona bien, pero si lo aplico habiéndolo agregado primero al ProcessContainer no funciona como se espera. Causa efecto pero aparentemente la máscara es considerada siempre como máscara directa. Es como si ProcessContainer no se diera cuenta que la máscara fue invertida.

En el ejemplo MT (aplicado a través de ProcessContainer) actúa siempre sobre el fondo, independientemente del estado de la máscara.

Saludos.
Alejandro.

Offline Juan Conejero

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 7111
    • http://pixinsight.com/
Re: ProcessContainer
« Reply #1 on: 2012 April 02 07:56:44 »
Hola Alejandro

This is normal behavior. The ProcessContainer process is not maskable. That is, the resulting image after applying the sequence of processes defined in a process container cannot be masked. However, each process instance inside a process container can have its own reference to a mask and its own mask inversion state, which always take precedence over the current mask of the target image. In other words, the current mask and mask inversion state of the target image are always ignored when a ProcessContainer instance is executed.

In your example, the MT instance has a reference to a mask image (Kleopatra_L) and no mask inversion. Hence, it is executed this way, irrespective of the current mask and mask inversion state of the image. Note that the MT instance would be masked directly with Kleopatra_L, even if the target image has no mask defined.

Although I recognize this behavior can be counterintuitive sometimes, this is the way ProcessContainer works, and it has to work precisely in this way because otherwise we couldn't encapsulate a sequence of processes as a self-sufficient object (e.g., an image's processing history). Always remember that processes and images are completely independent each other in PixInsight; this is just a consequence of that isolation.
Juan Conejero
PixInsight Development Team
http://pixinsight.com/