quagga2 icon indicating copy to clipboard operation
quagga2 copied to clipboard

Code128Reader properties should be changeable via Quagga Configuration

Open jogibear9988 opened this issue 4 years ago • 3 comments

For Example: AVG_CODE_ERROR

jogibear9988 avatar Dec 05 '19 15:12 jogibear9988

Hi @jogibear9988 could you please provide a more explicit description of what you're looking for?

Thanks!

ericblade avatar Dec 07 '19 01:12 ericblade

for example this: https://github.com/ericblade/quagga2/blob/99726f07d25be7b3d4a7fa880378be41e8de9426/src/reader/code_128_reader.ts#L122 i'd like to change the value via configuration

jogibear9988 avatar Jun 17 '21 21:06 jogibear9988

hmm. i don't recall ever seeing this issue, otherwise i would've said something on it. (though obviously I did like a year ago, apparently, so.. my apologies for not saying anything earlier!) On it's face, this seems like a pretty reasonable request, but I'm not entirely certain what the purpose of that is right off hand, if it's used, or how much of a change it would entail to be able to do that.

ericblade avatar Jun 20 '21 19:06 ericblade

I know it's been a long time since we've visited this issue, but I believe it should be pretty easily targetable in the 2.x release, as I think we'll probably be passing already instantiated BarcodeReader objects around, so you would be able to configure it as you desire at that time.

You can do this in the 1.x branch, however, by creating a new BarcodeReader class that extends the existing one, and overrides the AVG_CODE_ERROR value, then supplying your new reader in the setup.

ericblade avatar Sep 05 '22 08:09 ericblade

closing this as I believe we have an acceptable workaround for the current release, and future design should address it further. Please let me know if that is not the case, and re-open

ericblade avatar Sep 05 '22 09:09 ericblade