Closed Psychiquest closed 1 year ago
Thanks @Psychiquest 👍
Hi @mozmorris , Any plans for a new release that includes this change? It solves an issue with inconsistent screenshot dimensions I was facing. Thank you!
Yes, will sort today.
v7.1.0 (thanks!)
@jpserra Did the new version fix your issue? When I pull 7.1.0 version from npm, I don't get the updated code. Is there some issue with npm registry?
Hi @mozmorris https://github.com/mozmorris, can you re-publish the branch? The latest change has not been pushed in the latest version.
[image: Mailtrack] https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11& Sender notified by Mailtrack https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11& 06/07/23, 05:19:44 PM
On Tue, May 30, 2023 at 7:29 PM Warren Seine @.***> wrote:
v7.1.0 https://github.com/mozmorris/react-webcam/releases/tag/v7.1.0 (thanks!)
— Reply to this email directly, view it on GitHub https://github.com/mozmorris/react-webcam/pull/371#issuecomment-1568486528, or unsubscribe https://github.com/notifications/unsubscribe-auth/AI46EPA3CL6PPO5W5LF3L3DXIX4KZANCNFSM6AAAAAAXCI3KZU . You are receiving this because you were mentioned.Message ID: @.***>
Wow, indeed, the 2-line change doesn't seem to be included in the bundle 😬
Apologies @warrenseine @Psychiquest - need to migrate the prepublish in this package.
Patch has been released at 7.1.1
When the getScreenshot function gets called the first time, it creates a canvas object with given dimensions (if provided). From the next time onwards, it uses the same canvas to draw images. So, if someone passes different parameters the next time, it still uses the canvas built using parameters provided in the first time.
If we resize the canvas before drawing the image, it would resolve this issue.