Ensure that you have updated your iPad to the most recent version of iPadOS - at time of writing, this being iPadOS 17.5.1.
Have you had the iPad's screen replaced? If so, this may be reason that you are seeing this issue.
If the screen has not been replaced, the camera module itself may have a fault. You would be best advised to visit the Genius Bar at your local Apple Store or Apple Authorised Service Provider (AASP), where the technicians will be able to test and assess your iPad - and you can explore your available options:
Genius Bar Reservation and Apple Support Options - Apple