pub struct SWUMap<P: SWUConfig>(_);
Expand description
Represents the SWU hash-to-curve map defined by P
.
Trait Implementations§
source§impl<P: SWUConfig> MapToCurve<Projective<P>> for SWUMap<P>
impl<P: SWUConfig> MapToCurve<Projective<P>> for SWUMap<P>
source§fn new() -> Result<Self, HashToCurveError>
fn new() -> Result<Self, HashToCurveError>
Constructs a new map if P
represents a valid map.
source§fn map_to_curve(
&self,
point: P::BaseField
) -> Result<Affine<P>, HashToCurveError>
fn map_to_curve( &self, point: P::BaseField ) -> Result<Affine<P>, HashToCurveError>
Map an arbitrary base field element to a curve point. Based on https://github.com/zcash/pasta_curves/blob/main/src/hashtocurve.rs.