If a passport - even in the "express procedure" (within 3-4 days) - can no longer be issued in time before the start of your trip, you can obtain a temporary passport.
The current legal requirements for passport photos can be found under "Further information" - " Notes on digital passport photos ".
Unfortunately this specification of service has not yet been completely translated.