More likely than not, it's because of a hardware failure with the back camera. It seems to be a somewhat common issue with the Maxx, though it never happened to mine and I'm sure the majority of phones are fine.
You can try wiping the cache partition, restarting on safe mode to rule out a conflict with another application, or even a factory data reset (which, as the name suggests, erases all of your apps and data to start the phone from a factory fresh condition) to see if the camera works. But I'm afraid you'll find that the camera will either be flaky or won't work at all.
Press and momentarily hold the Power button (located on the right edge, above the volume buttons) until options menu appears then release.
Touch and hold Power off until the 'Reboot to safe mode' screen appears.
From the Reboot to safe mode screen, tap OK.
Note: Allow up to a minute for the device to reboot.
With Safe Mode enabled, test device and app functionality. If the previous issue fails to occur, the cause has been isolated to a third-party app and all recently installed or updated apps should be uninstalled.
Power cycle the device to disable Safe Mode, reinstall then test each app, one at a time, to identify which is causing the problem.
It's almost DEFINITELY a hardware problem. Not uncommon for the Droid Maxx and for the Moto X 2013. Sometimes, pushing in hard on the plate that includes the camera will make the camera reappear to the system for a while.
I would not bother wiping your phone in the hope that the camera will reappear--because all you'll likely do is create a headache for yourself.