T O P I C R E V I E W |
jeffp |
Posted - Jan 26 2016 : 11:23:27 I believe there may be a bug in TImageEnProc.Contrast.
When I set
TImageVect.Proc.Contrast(20); TImageVect.Update;
There is no visible change to the image. The text should get darker.
Also, what is interested is this. When I run
TImageVect.Proc.DoPreviews;
And then set Contrast to 20 on the Contrast tab in the Preview dialog, you can see the text in the image get darker in the "Result" image. But when you press the OK button, the images changes don't stick.
I can do the same exact thing with the "Brightness" setting and those changes do stick.
So there seems to be an issue with Contrast.
--Jeff
jp |
9 L A T E S T R E P L I E S (Newest First) |
xequte |
Posted - Feb 22 2016 : 17:24:33 Hi Jeff
Effects that try to change the color range will have no effect with black and white images, because you cannot stretch on/off.
The reason you are seeing a change in the preview dialog is because a quality filter is being used in the Preview dialog that converts the image to shades of gray. See your settings for IEGlobalSettings().DefaultPreviewsZoomFilter (and IEGlobalSettings().DefaultResampleFilter). Naturally, a gray scale image can be stretched.
You can test this executing this:
imageenview1.io.loadfromfile('Test.tif');
imageenview1.proc.ConvertTo24Bit();
imageenview1.Proc.Resample(200, -1, rfTriangle); // <- replacing rfTriangle with rfNone the subsequent proc.Contrast has no effect
imageenview1.proc.Contrast(100);
Generally none of the ppeColorAdjust effects are appropriate for 1bit images. I will add this to the documentation.
Nigel Xequte Software www.xequte.com nigel@xequte.com |
jeffp |
Posted - Feb 22 2016 : 09:34:04 Just checking up on this issue. Are you saying that there are certain edits in the Preview window that shouldn't be applicable to black and white images?
Will there be a resolution for this in the next build?
--Jeff
jp |
xequte |
Posted - Feb 11 2016 : 19:43:44 Hi Jeff
The image is 1bit, i.e. it only has pure white and pure black, so contrast should have no effect. So the question is why is the preview showing one? This is due to the use of a quality filter in the preview window.
Nigel Xequte Software www.xequte.com nigel@xequte.com
|
jeffp |
Posted - Feb 09 2016 : 20:50:45 Yes it is a 1 bit image and I am on the latest build of ImageEn.
Here is the image again.
attach/jeffp/201629205036_Test.zip 20.64 KB
jp |
xequte |
Posted - Feb 04 2016 : 17:03:04 Hi Jeff
You did not attach the image. Is it a 1bit (black and white) image?
What version of ImageEn are you using?
Nigel Xequte Software www.xequte.com nigel@xequte.com
|
jeffp |
Posted - Feb 04 2016 : 09:45:14 I did as you requested, but still no difference. Attached is the file I am using. I has no objects. It is just a scanned .tif file.
If I change the Brightness in DoPreviews, the change is reflected in the image when I press OK. But if I change the Contrast, I see the darkening of the text in the Preview, but when I press OK, the changes are not reflected.
--Jeff
jp |
w2m |
Posted - Feb 02 2016 : 10:18:28 It appears that you are doing a DoPreviews before CopyObjectsToBack. The DoPreviews acts only on the image and not the objects so call CopyObjectsToBack, then call DoPreviews:
procedure TfmeViewerImageEn.tbnAdjustmentsClick(Sender: TObject);
begin
viewImage.Proc.SaveUndo;
viewImage.CopyObjectsToBack;
if viewImage.Proc.DoPreviews(ppeColorAdjust, True, 850, 650) then
begin
viewImage.Update;
end
else
begin
viewImage.Proc.Undo;
end;
end; Bill Miller Adirondack Software & Graphics Email: w2m@hughes.net EBook: http://www.imageen.com/ebook/ Custom Commercial ImageEn Development |
jeffp |
Posted - Feb 02 2016 : 10:12:05 I guess I still don't follow. Below is my code and I've added the CopyObjectsToBack procedure as you mentioned, but it has no effect. Perhaps I still don't follow how to make the changes that appear in the Preview window part of my actual image.
viewImage below is my TImageEnVect. I'm adjusting the contract in the Preview window to make the text on my image look darker. It does in the Preview window, but when I click OK the main TImageEnVect doesn't reflect the change.
procedure TfmeViewerImageEn.tbnAdjustmentsClick(Sender: TObject);
begin
viewImage.Proc.SaveUndo;
if viewImage.Proc.DoPreviews(ppeColorAdjust, True, 850, 650) then
begin
viewImage.CopyObjectsToBack;
viewImage.Update;
end else
begin
viewImage.Proc.Undo;
end;
end;
jp |
xequte |
Posted - Jan 27 2016 : 13:14:22 Hi Jeff
Proc actions only apply to the image itself, not any objects upon it. You would need to apply the objects to the image (e.g. using CopyObjectsToBack) for the proc actions to take effect.
(DoPreviews shows a quick preview of the image, in this case it is not quite accurate because it shows the objects affected).
Nigel Xequte Software www.xequte.com nigel@xequte.com
|