Image copyright YouTube Image caption Ryan Arcand plays the piano in downtown Edmonton

The death of a homeless man who played piano on the street has left many mourning in the Canadian city of Edmonton, Alberta.

Ryan Arcand was used to the sounds of the city - cars honking, people shouting, the steady hum of traffic - while living on the street.

He died last week at the age of 46 after years of struggling with alcoholism, mental health and homelessness.

But the legacy of his music will live on.

A video of him playing a song he wrote on a piano in downtown Edmonton went viral on YouTube in 2014 with more than 11 million views.

Arcand was a member of the Alexander First Nation in Alberta and was placed in the foster-care system along with his brother at the age of three or four, family members told CBC. It was in foster care where the musician first found a piano in a basement.

"It was as though we were meant for each other," Arcand explained to the CBC shortly after the YouTube video went viral. "You're looking at the piano and you're falling in love with it."

He learned to play themes from television and movies by ear, and later began to write his own music.

At 13, he says he ran away to the city of Edmonton where he lived on the streets. Alcohol soon became the driving force in his life, but beneath the haze, his love of music persisted, he said.

He played on pianos in churches, hospitals and in Sir Winston Churchill square.

That was where Roslyn Polard discovered him one day, and took the video that would make him famous.

The song he played for her was appropriately called "The Beginning".

His newfound notoriety earned him the nickname "piano man" and helped get him into supportive housing. Polard used the money she made from the video to buy a piano for the housing complex's lobby so that he could play every day.

But he would soon begin shuffling between housing, the streets, jail and hospital for the next few years.

Soon he was barred from playing in Sir Winston Churchill square and many of his other regular spots after getting caught with open beer bottles.

"I've been drinking. It's terrible…I don't know what to do anymore," he told APTN television network in 2016 after a six-month stint in jail for petty crime.

"(My music) is a broken dream. A dream that could've been…There's no more hope out there for me, to be honest."

In mourning him, friends and family say they are remembering his character.

"In his best moments, he had a faith that really humbled me, as a priest," Rev Kris Schmidt, an associate priest at St Joseph's Basilica where Arcand sometimes attended church, told the CBC.

"When he wasn't drinking, he was a joy to have around."

His family will bury him on the Alexander First Nation this weekend.

"I find comfort in knowing his struggles that he went through, all that sadness ... is in the past," his cousin Chris Yellowbird told the CBC.