Measurements Made on Image Being Converted to Grayscale?

In this subforum specific Topics concerning ZEN Core, e.g workbenches, are discussed
Post Reply
user-5759
Posts: 6
Joined: Thu Jan 01, 1970 1:00 am

Measurements Made on Image Being Converted to Grayscale?

Post by user-5759 »

Hi,

It seems Zen is converting all graphic layers on my image to grayscale when saving. For graphics like the scalebar that are already some gray value, that is fine. However, it is a problem for caliper lines I draw across the image which are usually in red. Is there a line of code I'm missing when saving my image to not convert certain graphic layers to grayscale and keep their original color?

Thank you,
Craig
user-4
Posts: 397
Joined: Thu Jan 01, 1970 1:00 am

Post by user-4 »

It seems Zen is converting all graphic layers on my image to grayscale when saving.
Hello Craig,

we tried some graphical elements and the caliper as well but could not reproduce your case when saving and opening the file as czi.

To assist you we need further information on how you saved the image and e.g. the macro you used.

We use ZEN blue 2.3 with Service Pack 11.
user-5759
Posts: 6
Joined: Thu Jan 01, 1970 1:00 am

Post by user-5759 »

I am running Zen Core 2.4.72.0. The image is saved as a .tif using the following code:

Code: Select all

expSet=Zen.Processing.Utilities.Settings.SingleFileExportSetting(ZenExportFileType.TIFF) 
expSet.CreateFolder = False
Zen.Processing.Utilities.ExportSingleFile(image,expSet,pathAndFileName)
user-4
Posts: 397
Joined: Thu Jan 01, 1970 1:00 am

Post by user-4 »

Hello Craig,

we still have problems to understand your case.

First, the code you published

Code: Select all

Zen.Processing.Utilities.ExportSingleFile(image,expSet,pathAndFileName)
is not a valid call of Zen.Processing.Utilities.ExportSingleFile as pathAndFileName does not exist as parameter.
Please have a look at the IntelliSense!

Second, if saving an image as TIFF all graphics are lost as TIFF has no graphics layer and the graphics are just saved in a separate XML file.

Third, using a SingleFileExportSetting looks like this

Code: Select all

processingsetting1 = Zen.Processing.Utilities.Settings.SingleFileExportSetting(ZenExportFileType.TIFF)
processingsetting1.CreateFolder = True
processingsetting1.Compression = ZenTiffCompression.Lzw
processingsetting1.ConvertTo8Bit = True
processingsetting1.DestinationFolder = 'C:\Users\MyName\Pictures'
processingsetting1.SubsetString = ''
processingsetting1.MergedChannelsImage = True
processingsetting1.IndividualChannelsImages = False
processingsetting1.OriginalData = False
processingsetting1.ApplyDisplayCurveAndChannelColor = True
processingsetting1.BurnInGraphics = True
processingsetting1.UseChannelNames = False
processingsetting1.Resize = 1
processingsetting1.GenerateXMLFile = False
processingsetting1.Tiles = ZenTileMode.ReTile
processingsetting1.Columns = 1
processingsetting1.Rows = 1
processingsetting1.Overlap = 0
processingsetting1.GenerateZipFile = False
processingsetting1.Prefix = 'TestImage'

Zen.Processing.Utilities.ExportSingleFile(image1, processingsetting1)
In this case we burn in the annotations (with color) before the image is saved.

Please help us to better understand your case!
Post Reply