Allow assignment of "image priorities"

Bug #679974 reported by pniemayer
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Enblend
Triaged
Wishlist
Unassigned
Hugin
Triaged
Wishlist
Unassigned

Bug Description

Dear Hugin Developers,

I would love to see a feature in Hugin that allows to prioritize the usage of certain images when stitching a panorama over others.

Rationale: When I use hugin to stitch panoramas of landscapes that have significant details/features only in part of the whole panorama (like e.g. the image of desert with a tower visible, that has interesting ornaments) I use different focal lengths - short ones for the parts where little detail is to see, and zoomed images of the parts where lots of details are to see. I guess this is a common approach used by many users.

The problem is that while Hugin even detects and reports automatically there is "redundant coverage" of certain image areas, there seems to be no way to tell Hugin "Yes, I know, please prefer the long-focal-length pictures whereever available".

I can try to workaround by using the "crop" feature to crop all the wide angle pictures such that they do not overlap the zoomed in ones anymore, but that is an extremely tedious task especially if there are lots of pictures to stitch and when the difference in focal lengths is big.

I hope I haven't missed to spot an already existing feature like that, but searching for it didn't reveal any.

Regards,

Peter Niemayer

Revision history for this message
rew (r-e-wolff) wrote :

Workaround: first load all the short-focal length images, and only then the longer ones. Then enblend will get the longer focal length images last. Hmm. It might then call the image redundant and skip it alltogether. You need to cut a square out of the short-focal-length-one. Tedious task.

OK. Yes, wishlist....

Changed in hugin:
importance: Undecided → Wishlist
status: New → Triaged
Revision history for this message
Yuv (yuv) wrote : Re: [Bug 679974] Re: Allow assignment of "image priorities"

 tag imagestab

rew (r-e-wolff)
tags: added: enblend
rew (r-e-wolff)
tags: added: image priority
Revision history for this message
rew (r-e-wolff) wrote :

Could we use the alpha channel to indicate an image priority?

alpha=0 -> no image data.
alpha=1.0 -> normal: use this image.

alpha1 < alpha2 -> prefer using image 2.

this would lead to "special case" of alpha 1.0. It should be considered "medium priority" where images can come above and below. It would be most consistent, but have a painful transition period if we'd set the alpha to 0.5 by default.

Suppose I have two images.
11111111111111111111111111111111111111111111111111111111111
...............................2222222222222222222...................................

Of course "2" was taken with longer focal length, so it has more details. So I'd prefer image 2 to image 1. Currently enblend would say something like excessive overlap, and forget all about image 2. In fact it should cut everything on image 1 that is "far from the edge" of image 2 away and then do a normal blend.

Of course this requires some interesting coding in enblend......

Revision history for this message
rew (r-e-wolff) wrote :

Ah the commentbox has proportional font while the comment finally shows in fixed-width font. Anyway it still comes out reasonably.....

Revision history for this message
Yuv (yuv) wrote :

actually for what the reporter want to achieve the mask functionality is the way to go. Other than that, the priority is determined by the order of the images in the images tab.

Revision history for this message
rew (r-e-wolff) wrote :

Yuv, If I have "half-a-person" on a picture, I know I don't want that in the final picture. This is easily masked.

If I have a full person on a picture I might want to mark it as: "please include all this", because otherwise enblend might cut of a head or a foot. These are the red and green areas in "ptgui".

What I was suggesting is that we use the alpha mask for both of these cases. 0.5 means: blend allowed, 0.7 means prefer this image, 0.3 means prefer other picture, 1.0 means This image data HAS to be used (i.e. it's an error to have another image with 1.0 alpha mask at that pixel).

I might have a 18mm pano shot from the same location as my 135mm pano. So I'd want to prefer the pixels from the 135mm one over the ones from the 18mm one. If I can arrange the priorities with the order, do I place the low res one first or the high res one?

Changed in enblend:
importance: Undecided → Wishlist
status: New → Triaged
Revision history for this message
tmodes (tmodes) wrote :

> If I have a full person on a picture I might want to mark it as:
>"please include all this", because otherwise enblend might cut
> of a head or a foot. These are the red and green areas in "ptgui".

This can also be done easily by masking.

> What I was suggesting is that we use the alpha mask for both of these cases.
> 0.5 means: blend allowed, 0.7 means prefer this image, 0.3 means
> prefer other picture, 1.0 means This image data HAS to be used
> (i.e. it's an error to have another image with 1.0 alpha mask at that pixel).

First, that will break existing functionality.
Second, then will need to generate accurate masks if you want to force to include a specific area. This can be done more easily by masking.

Revision history for this message
Yuv (yuv) wrote :

On December 7, 2010 08:00:55 am rew wrote:
> Yuv, If I have "half-a-person" on a picture, I know I don't want that in
> the final picture. This is easily masked.

Thomas answered this one.

> If I have a full person on a picture I might want to mark it as:
> "please include all this", because otherwise enblend might cut of a head
> or a foot. These are the red and green areas in "ptgui".

Thomas implemented this feature in Hugin before "ptgui" even thought of masks.

> I might have a 18mm pano shot from the same location as my 135mm pano.
> So I'd want to prefer the pixels from the 135mm one over the ones from
> the 18mm one. If I can arrange the priorities with the order, do I place
> the low res one first or the high res one?

Arrange them in the Images Tab so that the 135mm ones are first. The order in
the Images Tab already allows the assignment of "image priorities" and the
positive and negative masks in the Mask Tab give all the necessary finer
grained controls.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.