When using my Panasonic DMC-FZ2000 with the lens at its widest focal length (24mm), I can see the lens hood on the top and the bottom of the picture when shooting in RAW. However, it is not visible at all when using JPEG. The problem goes away when I remove the lens hood, so it's not a simple vignetting issue. There is noticeable barrel distortion on the RAW image.
Can anyone explain this behavior?