How can enable cv.imencode and cv.imdecode in opencv.js

i set {} {} as follows:

imgcodecs = {‘’: [‘imdecode’, ‘imencode’]}
white_list = makeWhiteList([imgproc, calib3d, imgcodecs])

but The opencv.js I packaged not have imgcodecs,
so what problem is,

that’s on purpose. if you’re using it from the webbrowser, use a canvas to decode images

see e.g. discussion here:

thank you very much。。。。。。。