You might want to unlock the bootloader to flash back to an old factory image, but more likely you’re wanting to install a custom ROM and work outside of the Samsung Sandbox. Most root users know that with great configurability comes having to do many many things in order to get the basics to work, but getting the cameras to work has never been a problem. Until now.
Samsung’s Z Fold 3, when the bootloader is unlocked, disables the camera.
Locking the bootloader again evidently will allow the cameras to work, but it’s unclear from the source article if relocking while a custom ROM is on fixes thing, or if it requires flashing back to the factory image.[xda-developers]