pub fn build_shield_transition<S: Signer<PlatformAddress>, P: OrchardProver>(
recipient: &OrchardAddress,
shield_amount: u64,
inputs: BTreeMap<PlatformAddress, (AddressNonce, Credits)>,
fee_strategy: AddressFundsFeeStrategy,
signer: &S,
user_fee_increase: UserFeeIncrease,
prover: &P,
memo: [u8; 36],
platform_version: &PlatformVersion,
) -> Result<StateTransition, ProtocolError>Expand description
Builds a Shield state transition (transparent platform addresses -> shielded pool).
Constructs an output-only Orchard bundle (no spends), proves it, signs the
transparent input witnesses, and returns a ready-to-broadcast StateTransition.
§Parameters
recipient- Orchard address to receive the shielded noteshield_amount- Amount of credits to shieldinputs- Platform address inputs with their nonces and balancesfee_strategy- How to deduct fees from the transparent inputssigner- Signs each input address witness (ECDSA)user_fee_increase- Fee multiplier (0 = 100% base fee)prover- Orchard prover (holds the Halo 2 proving key; cache withOnceLock— ~30s to build)memo- 36-byte structured memo for the recipient (4-byte type tag + 32-byte payload)platform_version- Protocol version