function [] = plot_bc_ids(NodeP, Mask)
%%
    Nbcs = max(Mask(:)) + 4;    
    [x, y] = meshgrid(1:size(NodeP, 2), size(NodeP, 1):-1:1);
    colors = jet(Nbcs);
    colormap(jet(Nbcs));
    hold on
    for i = 1 : Nbcs
        ids = (NodeP == i);
        plot(x(ids), y(ids),'o', 'MarkerEdgeColor', colors(i, :),...
            'MarkerFaceColor', colors(i, :));
        text(mean(x(ids(:))), mean(y(ids(:))), num2str(i), 'FontSize',14);
    end;
    caxis([1, Nbcs]);
    axis tight
    