Get histogram of edge lengths/orientations in an image using OpenCV In the process of trying to estimate whether a ROI contains [Japanese] text, I need to get a rough count of edges, hopefully binned by length and/or orientation... I think this would give me strong-enough features to judge if the ROI is likely to contain text or not.

However, I can't seem to figure out an efficient (this eventually has to work on a video stream) way to get such a histogram (or even just a count of edges for certain length/orientation threshold): Hough transforms will tend to focus on certain shapes (lines etc.) while Canny and Sobel will detect any type, but their output is not particularly useful for counting...

I would appreciate any suggestion or hint at some algorithm I can use, to quickly extract a list of edges from an image...
I don't know if OpenCV has some implementation - but i can provide you with a pointer of algorithm for this. 

MPEG 7 provides a fairly well defined (and well thought out) edge histogram descriptor [EHD] which essentially serves your purpose. 

You can refer to this: Efficient Use of MPEG-7 Edge Histogram Descriptor which i think is an excellent paper on this. 

If you want to see some implementation of MPEG-7 you can find it on JOANNEUM RESEARCH MPEG 7 page. 

For more information on MPEG-7: List of possible image features for content based image retrieval