That depends on what rom you flash. There are basically we kinds of roms for the S4, Touch wiz based roms, and Aosp roms. Touch wiz roms are roms built off of your phones stock software. The software made my Samsung for the S4. If you flash one of these you will keep your TW camera and gallery...