Do a WhatsApp backup. Go to Settings > Apps > WhatsApp > Force stop > Storage > Clear cache > Uninstall.
Reinstall WhatsApp and see if this continues.
As asked earlier- this only happens on whatsapp? Does your camera work as normal on the main camera app/ other messaging services? Then Id suggest reaching out to samsung support directly
Hi ,thank you so much I have done all that, and it happens only on WhatsApp, but my WhatsApp business is working perfectly, just my personal WhatsApp that is having this issue