one fing leads . . .

Edge Detect by Brightness Level and Hue Difference
Where there is a brightness difference between adjoining pixels, it might be perceived as part of an edge. There are some standard, or widely-used, mechanisms for edge detection, see my page Edge Detection Scripts. The method often recommended, that devised by J. F. Canny in 1986, looks at adjoining brightness differences but it does that in an absolute fashion. This page is more selective, with the aim more of identifying shapes, rather than drawing a line around every shape. More about this on Edge Detection Scripts.
Select any number of points on the table of 256 brightness levels, or this can be done automatically where the software will identify equal number of brightnesses among the pixels in the image. Each selection therefore forms a band, from the lower brightness level selected to itself. For each pixel, the script identifies the band that its brightness falls in, as is the band of the pixel to the right of it and that immediately below it on the image, the higher of the differences between these two, i.e. the one to the right and the one below, and the brightness of the pixel being looked at, provides a value between 0 and 255, this value is used to determine the opacity of the output pixel, the higher the value the more opaque, with its colour being that which is given as the top of the band by the user.
That sounds a little complex, though is in fact more difficult to explain that it is to code, the code is quite concise. And it seems to work very well, and be quite flexible in getting towards the determination of shapes. It is somewhat different from the approach taken by Canny and those who have extended his work, but works better for what I am trying to achieve.
or image url apply
  – see copyright notice
This page requires a HTML5 browser and Javascript switched on.
No.of Brightness Breaks for Lines
from image bgtness
equally spaced
auto dark-light
auto light-dark
spread on lookup pixels
(fixed) line colour
background colour
background transparent on fullsize
Edge lines determined:
by brightness percent
by brightness break selection
by hue only
Hue tolerance °
brightness–hue relationship: and or
No of pixels per blob (fullsize only)
Fill lines every line breaks
Ignore opacity below %
No transparency Knock out adjoining
Knock out floating blobs (not implemented yet)
Max pixels considered a floater
Max blanks horiz or vert considered separator
Treat opacity as blank below %
Formula for calculating brightness:

more experiments for the sake of my dreams