Opened 15 years ago
Closed 14 years ago
#2024 closed enhancement (fixed)
Add Raster Stretching/Enhancement based on portion of image in current window
Reported by: | jgr007 | Owned by: | nobody |
---|---|---|---|
Priority: | minor: annoyance | Milestone: | Version 1.6.0 |
Component: | Rasters | Version: | Trunk |
Keywords: | contrast stretching, contrast enhancement | Cc: | |
Must Fix for Release: | No | Platform: | All |
Platform Version: | Awaiting user input: | no |
Description
I'd like to have the option to do enhancement/stretching based on the statistics of the portion of the image displayed in the current window (vs. stats of entire image). I posted a message to the developer list and Peter Ersts suggested that this would be a good one to add to the code base and asked that I file a ticket on it. Hopefully this is the right way to do that. :)
Change History (5)
follow-up: 2 comment:1 by , 14 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:2 by , 14 years ago
Resolution: | fixed |
---|---|
Status: | closed → reopened |
Replying to ersts:
It turns out this actually would have been a little easier as a plugin, but it should be core functionality. The issue at hand is that the layer itself does not know what is currently being display. draw() accepts a render context object which is used to determine what portion of the layer to display, but that object comes from the map canvas.
There is a solution in the trunk now, r 12015.
What a handy addition to qgis! I was thinking that it would be nice to have this functionality available using the legend right click menu.
comment:3 by , 14 years ago
Milestone: | → Version 1.4.0 |
---|
comment:4 by , 14 years ago
Milestone: | Version 1.5.0 → Version 1.6.0 |
---|
comment:5 by , 14 years ago
Resolution: | → fixed |
---|---|
Status: | reopened → closed |
The option "Stretch using current extent" was added to the right-click legend menu in r14031. This option is not available for "Palette" layers. If this menu option is selected while displaying a single band with a color map or as pseudo color, it will switch the layer back to gray scale. Additionally if, you to not have a contrast enhancement set stretch to min max will automatically be selected.
It turns out this actually would have been a little easier as a plugin, but it should be core functionality. The issue at hand is that the layer itself does not know what is currently being display. draw() accepts a render context object which is used to determine what portion of the layer to display, but that object comes from the map canvas.
There is a solution in the trunk now, r 12015.