How to get polygon points in Fabric.js
问题 I am drawing polygon by capturing mouse clicks on canvas and then passing these points to fabric.Polygon . So, in this manner I'm drawing multiple polygons. What I need know is, I want to get the mouse co-ordinates (pixel points on canvas) for the polygon which is selected now? I have tried with: canvas.getActiveObject().get('points'); But this is giving some negative and some positive values. So, can u please tell me a way to find out the polygon points? 回答1: Polygon points are relative to