A masked man took hostages at a cinema in western Germany on Thursday before police stormed the complex and shot him dead, police said.

No other people were injured, a police spokesman said.

The attacker, who carried a rifle or "long gun", acted alone and appeared to have been a "disturbed man", the interior minister of Hesse state, Peter Beuth, told the regional parliament.

Police had not identified the man or established his motive, spokesman Bernd Hochstaedter said, adding that nothing immediately pointed to him having a militant background.

German television showed pictures of heavily-armed police, wearing helmets and body armour, storming the Kinopolis complex in Viernheim, south of Frankfurt, and a couple fleeing the building.

Cinema employee Guri Blakaj told Reuters the gunman, who appeared to be aged between 18 and 25 and was about 1.7 metres tall, entered the cinema at around 3 p.m. and told workers to get into an office.

He then went into a cinema theatre. Blakaj, who said there were about six workers and 30 cinemagoers in the building, then heard shots fired.

Police special forces stormed the building and shot him.

There was still a heavy police presence at the scene into the late afternoon, and a helicopter circled overhead.

Reports earlier said more than 20 people had been injured. German media said later than most of those injuries were apparently from tear gas inhalation.