NewEncoder creates and inits a new encoder for the given chunk length.
(n int)
| 15 | |
| 16 | // NewEncoder creates and inits a new encoder for the given chunk length. |
| 17 | func NewEncoder(n int) *Encoder { |
| 18 | return &Encoder{ |
| 19 | chunkLen: n, |
| 20 | redundancyFactor: 2.0, |
| 21 | } |
| 22 | } |
| 23 | |
| 24 | // Encode encodes data from reader and splits it into chunks to be |
| 25 | // futher converted to QR code frames. |
no outgoing calls