pointAdd static method

List<int> pointAdd(
  1. List<int> point1,
  2. List<int> point2
)

add two point r = P+P1

Implementation

static List<int> pointAdd(List<int> point1, List<int> point2) {
  final pk1 = CryptoOps.geFromBytesVartime(point1);
  GroupElementCached ec = GroupElementCached();
  CryptoOps.geP3ToCached(ec, pk1);
  final pk2 = CryptoOps.geFromBytesVartime(point2);
  GroupElementP1P1 r = GroupElementP1P1();
  CryptoOps.geAdd(r, pk2, ec);
  GroupElementP2 r1 = GroupElementP2();
  CryptoOps.geP1P1ToP2(r1, r);
  return CryptoOps.geTobytes_(r1);
}