Fig. (3)
The mask considering the weighted neighborhood gray values.