LEADTOOLS Support
General
General Questions
LineProfileClass.Run() returning different array lengths.
This topic and its replies were posted before the current version of LEADTOOLS was released and may no longer be applicable.
#1
Posted
:
Wednesday, November 28, 2007 6:02:29 AM(UTC)
Groups: Registered
Posts: 28
I'm using LineProfileClass.Run() on a RasterImage to get pixel information for a given line. My understanding after reading the documentation about the class is that, for a horizontal line the Run() method should populate the three arrays, each with a length equivalent to the width of the given line (consider the line to be horizontal for simplicity). My program used to work fine on a wide array of images, but something appears to be wrong now. It appears that the arrays returned are of different lengths (which caused my program to throw an exception), and all three of the lengths are less than the length of the line identified by the StartPoint and EndPoint property.
I see in the documention that the class does support 12/16 bit grayscale and 48/64 bit color but in medical only. Does that mean that other image formats aren't supported in version 15? I recently changed from 14 to 15 -- could that have caused a problem, or is my understanding of how the command works in error?
Thanks for your time.
Matt
#2
Posted
:
Wednesday, November 28, 2007 8:04:28 AM(UTC)
Groups: Registered
Posts: 28
I downloaded a patch for another issue and that fixed it. Sorry for taking your time.
Matt
#3
Posted
:
Thursday, November 29, 2007 4:11:22 AM(UTC)
Groups: Registered
Posts: 28
I still have a little bit of a problem.
In the original application, I allowed the user to place the image in "Profile" mode, which in essence graphed the RGB values returned by LineProfileClass.Run() directly on the image. The StartPoint and EndPoint values were calculated from the mouse position. Originally, my application allowed the user to hold the mouse down and scroll around the picture and the graph happened in real time. Now there is some latency associated with the Run() command. I know it's the Run() and not the drawing because I have commented out both to identify the bottle-neck.
I'll bet there is some kind of property or flag somewhere that I'm not setting properly or something like that. Could you help me identify why I would have that latency with the Run() command? I'm using Leadtools.ImageProcessing.Color.dll version 15.0.0.3 for .NET.
Thanks a lot.
Matt
#4
Posted
:
Sunday, December 2, 2007 12:31:23 AM(UTC)
Groups: Registered, Tech Support
Posts: 1,326
Was thanked: 1 time(s) in 1 post(s)
Hello,
A major performance hit can happen if you run your code inside the Visual Studio .NET debugger. This is because of the way the debugger loads our DLLs. Please try to perform your test by building a Release EXE and running it at full speed outside the Visual Studio IDE.
Thanks,
Maen Badwan
LEADTOOLS Technical Support
#5
Posted
:
Monday, December 3, 2007 10:03:42 AM(UTC)
Groups: Registered
Posts: 28
You are absolutely correct. I tried running it in release mode before my last post, but that's not the same thing as building a release and running it outside of the Visual Studio environment. Once I did that, the latency disappears.
Thanks for the info.
Matt
LEADTOOLS Support
General
General Questions
LineProfileClass.Run() returning different array lengths.
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.