iddan / react-native-canvas

A Canvas component for React Native
MIT License
981 stars 172 forks source link

getting an Object instead of Boolean by using isPointInStroke #336

Closed gun-ctrl closed 2 months ago

gun-ctrl commented 2 months ago

This is part of my sample code: This method is used to determine the effective click range,I get an Object instead of Boolean and there are no error

cxt = canvas.getContext('2d'); function isInCricle(x, y) { cxt.beginPath(); cxt.lineWidth = arcRadio; cxt.arc(center, center, radius, Math.PI 0.32, Math.PI 0.68, false); return cxt.isPointInStroke(x, y); }