I don't know enough about zk-snarks to say if your method is good enough or not, but recently this bip-ZZZ (
https://github.com/jl2012/bips/blob/vault/bip-0ZZZ.mediawiki ) was published that I does what you want to achieve in an easier way IMO.
PUSHTXDATA type
15 is
TXDATA_VOUT which for a specified output index, first pushes the amount that is being sent to the output, then the scriptPubKey which the amount is sent to. The type
3 pushes the amount in the input being redeemed.
So if you wanted a script that would always have to pay any amount sent to it to some pre-specified address, say
mkqHTnuZ6icRzRms2fTyQU75fRqifpKFGb, you could program :
15 PUSHTXDATA 0x19 0x76A9143A501DE5E8B8A15856CD22A4BD9E5A1BE4C2E5AF88AC EQUALVERIFY 3 PUSHTXDATA EQUAL
Now if you fund this scriptpubkey, to use it as an input in some transaction, you must also include
mkqHTnuZ6icRzRms2fTyQU75fRqifpKFGb in one of the outputs, and make sure that the amount in the utxo that you are redeeming is paid in full to that address.
I'm not even bothering with adding any checksigs or handling keys because the worst that could happen is that my address will get paid.
You could add more types of PUSHTXDATA and be a bit more clever with amount checks to even encode some pre-specified allowed fees (or hard code a subtraction of just *this* input and output's worth)
A cool post on the subject :
https://blockstream.com/2016/11/02/covenants-in-elements-alpha.html