Media playback is unsupported on your device Media caption Operation Lattise led to the seizure of 30 million indecent images

More than 500 children have been identified as potential victims of online sexual abuse during a major investigation by Police Scotland.

The force said 30 million indecent images were seized and 77 people had been charged during Operation Lattise.

The charges include rape, sharing indecent images of children and grooming for sexual purposes.

Of the 523 potential victims, some as young as three, 122 have been referred to child protection services.

The operation, which involved 134 separate investigations, was carried out between the 6 June and 15 July.

Police said child victims had been found after the homes of 83 suspects were searched and 547 computers and other devices seized during the five-week operation.

'Horrific acts'

Almost 400 charges have been brought so far, including rape, sharing indecent images of children, grooming for sexual purposes, sexual extortion, indecent communication with children, possession of a firearm, bestiality and drugs offences.

In one instance, a computer that featured 10 million images depicting child abuse was found. Police Scotland said it would take four full-time officers six months just to view the number of images uncovered.

Child abuse investigation 30 million Images of abuse recovered 523 potential child victims

122 referred to child protection

83 suspects' homes searched

77 people arrested and charged Thinkstock

Assistant Chief Constable Malcolm Graham, who led the investigation, said: "This is not sexting in terms of people sending abusive messages to each other.

"This is children being sexually abused and these images being shared.

"It is about real victims in Scotland and elsewhere. It's about these horrific acts which ruin people's lives and we need to make sure that stops."

Media playback is unsupported on your device Media caption Police Scotland on online child abuse investigation: 'cases never cease to horrify'

Mr Graham called on parents and carers to be "alert" but not alarmed and said there were people in society who used technology to identify children who may be vulnerable to exploitation.

The investigation involved officers analysing in excess of 100,000 online chat logs.

Examination of one device led officers to conclude that one adult suspect had been sexually communicating with more than 110 children and young people.

Det Insp Andy McWilliam, who was also involved in the investigation, said that new technology meant there was no way for perpetrators to hide or erase what they had done online.

'Covert technology'

He said: "Whether they throw the computer in the bath or not, we can find what they have looked at. And we can use covert technology to identify who you are and where you are.

Image caption Malcolm Graham said the investigation was about identifying real victims in Scotland and elsewhere

"These individuals want to be wherever children are. They are using websites, chatrooms and forums.

"These men - and it is predominantly men - are using the profiles of younger children to groom them and offend against them."

Police are also working with young people and parents to help raise awareness of the potential dangers of the internet.

They said a key aim was to prevent abuse from happening in the first place.

Figures from Police Scotland have shown that the number of recorded offences are growing each year.

In 2014-15, there were 23 offences of grooming children for the purposes of sexual offences. Last year it was 50 - an increase of 117%.

The offence of taking, distributing or possessing indecent images of children increased from 605 in 2014-15 to 645.

NSPCC Scotland policy and public affairs manager Joanna Barrett said the charity was becoming increasingly concerned about the harm caused to children through online activity.

Image copyright Xavier_S/Thinkstock Image caption In one instance Police Scotland found a suspect had made contact with 110 children

She said too many children were being exposed to dangerous and harmful content through the internet or were subjected to online harassment, grooming and sexual exploitation.

She said: "We recently highlighted how the internet is playing an increasing role in the sexual abuse of younger children in Scotland, with a 60% rise recorded over a year in the number of indecent communications offences carried out by adults against children aged under 13."

Early years minister Mark McDonald said the Police Scotland operation would help the government hone future child protection programmes.

He added: "Children and young people should be able to enjoy and learn from the internet, but we also want them to stay in control and know what to do and who to go to if they feel at risk.

"Keeping children safe is a priority for both Police Scotland and the Scottish government, so although there are many positive aspects to the online world I recognise, there are also risks we have to be aware of."