H.264 pros/cons
+ reduces bandwidth and storage consumption significantly
+ adaptive video quality based on bandwidth
+ suitable for storage
+ / –  complexity setup – sometimes tricky to set up – streaming quality, frame rate, and frame rate. GOP, VBR, CBR, etc.

MJPEG pros/cons
+ consistently great image quality
+ robustness, if one frame is dropped, then it does not affect the video
– no sound 
– consumes much more bandwidth and storage