ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 Histogram of raw, unadjusted data

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

View 
UserName:
Password:
Format  Bold Italicized Underline  Align Left Centered Align Right  Horizontal Rule  Insert Hyperlink   Browse for an image to attach to your post Browse for a zip to attach to your post Insert Code  Insert Quote Insert List
   
Message 

 

Emoji
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Black Eye [B)]
Frown [:(] Shocked [:0] Angry [:(!] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
tedfine Posted - Nov 06 2017 : 18:01:24
My application involves image analysis of low light images taken with DSLRs.

I want to show my users three histograms (R, G, and B) so they can see if they have sufficient exposure levels (> ~40k in our application) but not larger than ~55k where non-linearity may occur, AFAIK.

I'm having trouble with bit depth and automatic adjustments made by ImageEn.

I don't want ImageEn to adjust exposure levels. In other words, if an image is under-exposed, I don't want the pixels values stretched. (Does IsNativePixelFormat := TRUE turn off that function?)

And, I'd like to use THistogrambox if I can. THistogrambox only works with ie24RGB images though.

I suspect I'm going about it all wrong.

My latest attempt:

1. Read in Native Pixel format using TIEBitmap.Read with IsNativePixelFormat := TRUE
2. Divide all pixels by 255 (to scale them down from 0..65k to 0..255)
3. bmp.PixelFormat := tiepixelformat.ie24RGB;
4. Update the histogram with the bmp. (and turn off the x-axis label in the histogram, so that "255" isn't shown as the max x-value. Replace it with a nearby TLabel that says "64k"

But in step 2, on the line below the compiler says that Left side can not be assigned to:

bmp.Pixels_ie48RGB[Column, Row].B := bmp.Pixels_ie48RGB[Column, Row].B / 255;

Plus, the above procedure seems rather convoluted. I'm not sure it will work, or if converting the image to ie24RGB will trigger some sort of other unwanted changes to the data. I'm hoping there's an easier way to accomplish my goal.

Along the way, I've unintentionally configured the engine to not apply any corrections, which results in very noisy images. I'm not sure now how I did that, but I *think* that's the mode I want.

Clearly, there's a lot I don't understand about the engine and raw images.

Any suggestions?





1   L A T E S T    R E P L I E S    (Newest First)
xequte Posted - Nov 07 2017 : 18:55:59
Hi

Rather than modidying the bitmap in some unexpected way, create a TIEHistogram with your values scaled 0.255.

Then pass that histogram to THistogramBox using UpdateFromHistogram.

Nigel
Xequte Software
www.xequte.com
nigel@xequte.com