document the circle percentage radius algorithm

This commit is contained in:
Horcrux
2016-04-25 23:46:04 +08:00
parent 1304e3fc49
commit 76856ce457
2 changed files with 6 additions and 0 deletions
+3
View File
@@ -43,3 +43,6 @@ ios/marry/main.jsbundle
# unfinished documents # unfinished documents
# #
cn-doc.md cn-doc.md
experimental code
experimental/
+3
View File
@@ -13,7 +13,10 @@ import createReactNativeComponentClass from 'react-native/Libraries/ReactNative/
const CIRCLE = 0; const CIRCLE = 0;
/** /**
* coord props
* *
* algorithm for radius in percentage
* radius = Math.sqrt(Math.pow((width*percent), 2) + Math.pow((height*percent), 2)) / Math.sqrt(2);
*/ */
const CIRCLE_COORDS = ['cx', 'cy', 'r']; const CIRCLE_COORDS = ['cx', 'cy', 'r'];