How do I display velocity vectors of different pixels of an image over the image?
How do I display velocity vectors of different pixels of an image over the image?
I have an array of vectors( vx and vy for each pixel). I want to display velocity vectors(by arrows of corresponding magnitude and direction). I need to know how to use the velocity vector data( 2 arrays vx and vy) to a graph/chart/image showing arrows. This is part of work to display the output of开发者_运维问答 optical flow(image processing)
You can use a drawing library such as this one (native to Java SDK), to draw lines over your image: http://download.oracle.com/javase/1.4.2/docs/api/java/awt/Graphics.html
精彩评论