Police officers may not confiscate or demand to view your digital photographs or video without a warrant. The Supreme Court has ruled that police may not search your cell phone when they arrest you, unless they get a warrant. Although the court did not specifically rule on whether law enforcement may search other electronic devices such as a standalone camera, the ACLU believes that the constitution broadly prevents warrantless searches of your digital data. It is possible that courts may approve the temporary warrantless seizure of a camera in certain extreme “exigent” circumstances such as where necessary to save a life, or where police have a reasonable, good-faith belief that doing so is necessary to prevent the destruction of evidence of a crime while they seek a warrant.

Police may not delete your photographs or video under any circumstances. Officers have faced felony charges of evidence tampering as well as obstruction and theft for taking a photographer’s memory card.

Police officers may legitimately order citizens to cease activities that are truly interfering with legitimate law enforcement operations. Professional officers, however, realize that such operations are subject to public scrutiny, including by citizens photographing them.

Note that the right to photograph does not give you a right to break any other laws. For example, if you are trespassing to take photographs, you may still be charged with trespass.

Source: https://www.aclu.org/know-your-rights/photographers-what-do-if-you-are-stopped-or-detained-taking-photographs