RistrettoPoint.fromEdwardsPoint constructor

RistrettoPoint.fromEdwardsPoint(
  1. EDPoint point
)

Create a RistrettoPoint from an EdwardsPoint.

Parameters:

  • point: An EdwardsPoint to derive the RistrettoPoint from.

Implementation

factory RistrettoPoint.fromEdwardsPoint(EDPoint point) {
  final coords = point.getCoords();
  return RistrettoPoint._(
    curve: point.curve,
    x: coords[0],
    y: coords[1],
    z: coords[2],
    t: coords[3],
    generator: point.generator,
    order: point.order,
  );
}