v-viewer icon indicating copy to clipboard operation
v-viewer copied to clipboard

Drawing on top of the images

Open askari12 opened this issue 3 years ago • 3 comments

Hello, I'm using your viewer for a project. I need to be able to draw boxes on top of the images, I was trying to embed an html5 canvas on top of the image but that didn't work properly. Can you help me on how to draw on top of images ?

askari12 avatar Sep 02 '20 10:09 askari12

Is this what you mean? https://codepen.io/mirari/pen/pobbdoE

mirari avatar Oct 19 '20 08:10 mirari

Hi @mirari :) Not quite exactly. This was how I was doing it myself as well. The canvas isnt able to move the same way the image does with respect to zooming, rotating and all stuff like that. Would there be a way to have the canvas move with the images as well ?

I would really appreciate the help ! :D

askari12 avatar Oct 27 '20 04:10 askari12

I'm afraid it's hard to do in the current version of viewerjs, you can make a feature request to viewerjs, change .viewer-canvas > img to .viewer-canvas > div > img

mirari avatar Oct 29 '20 02:10 mirari