The funeral procession on a gray, freezing day was accompanied by top military and party officials, but there was little doubt who the leader was. Son and successor Kim Jong Un served as head mourner, walking with one hand on the hearse, the other raised in salute, his head bowed against the wind.
State media - which over the past week have called Kim Jong Un "great successor," ''supreme leader" and "sagacious leader" - made it clear that the family's hold on power would extend to a third generation, declaring the country in the younger Kim's "warm care."
At the end of the procession, Kim Jong Un again walked along with the limousine with his hand cocked in a salute. He stood head-bowed with top officials as rifles fired 21 times, then saluted again as goose-stepping soldiers carrying flags and rifles marched by.
The funeral procession, which began and ended at Kumsusan Memorial Palace, where Kim's body had lain in state and where his father, North Korean founder Kim Il Sung, is preserved, passed by huge crowds of mourners, most of them standing in the snow with their heads bare, many screaming and flailing their arms as soldiers struggled to keep them from spilling onto the road.
"How can the sky not cry?" a weeping soldier standing in the snow said to state TV. "The people ... are all crying tears of blood."
The scenes of grief provide a clue at how effective North Korea has been in building a personality cult around Kim Jong Il even though people have suffered greatly from food shortages and the United Nations and others cite a lack of human rights. The North's neighbors and the United States are also pressing Pyongyang to abandon its nuclear weapons program.
Kim, who led the nation with an iron fist following his father Kim Il Sung's death in 1994, died of a heart attack Dec. 17 at age 69, according to state media.
Even as North Koreans mourned the loss of the second leader the nation has known, the transition of power to Kim Jong Un was under way. The young man, who is in late 20s, is already being hailed by state media as the "supreme leader" of the party, state and army.
Like his father's in 1994, Kim Jong Il's coffin was wrapped in a red flag. A limousine carrying a huge portrait of a smiling Kim led the procession, and soldiers followed the hearse and lined the streets. A national memorial service will take place at noon Thursday, state media said. Foreign diplomats in Pyongyang were told to prepare to attend the service.
Outside observers will be watching Wednesday's footage closely for clues on the makeup of Kim Jong Un's inner circle.
Walking behind him was Jang Song Thaek, Kim Jong Il's brother-in-law and a vice chairman of the powerful National Defense Commission who is expected to play a crucial role in helping Kim Jong Un take power.
Also escorting the limousine were military chief Ri Yong Ho and People's Armed Forces Minster Kim Yong Chun. Their presence indicates they will be important players as the younger Kim consolidates his leadership. Top Workers' Party officials Choe Thae Bok and Kim Ki Nam and senior military officer Kim Jong Gak also were prominent positions, according to Seoul's Unification Ministry.
"It shows they will be core powers in North Korea," said Yoo Ho-yeol, a professor at Korea University in South Korea. "Particularly, Jang Song Thaek and Ri Yong Ho will be key to Kim Jong Un's leadership."
The military presence at the funeral Wednesday also suggests Kim will uphold his father's trademark military-first policy, Yoo said.
After the funeral, the young Kim is expected to cement his power by formally assuming command of the 1.2 million-strong military, and becoming general secretary of the Workers' Party and chairman of the party's Central Military Commission, Yoo said.
Kim Jong Il's two other sons, Kim Jong Nam and Kim Jong Chol, have not been spotted.
Kim Jong Un made his public debut just last year with a promotion to four-star general and an appointment as vice chairman of the Central Military Commission of the ruling Workers' Party.
Earlier, state television also replayed images of missiles being fired and the April 2009 long-range rocket launch that earned North Korea strengthened U.N. sanctions. The U.S., South Korea and other nations called it a test for a missile designed to strike the United States; North Korea said the rocket sent a communications satellite into space.
North Korea's officials have pledged their loyalty to Kim Jong Il's son.
In an essay paying homage to Kim Jong Il on Wednesday, Workers' Party mouthpiece Rodong Sinmun said North Korea under his leadership had been "dignified as a country that manufactured and launched artificial satellites and accessed nukes," referring to the country's nuclear program.
"Thanks to these legacies, we do not worry about the destiny of ourselves and posterity at this time of national mourning," the essay said, carried in English by the Korean Central News Agency.
"Supreme leader of our party and people Kim Jong Un takes warm care of the people left by Kim Jong Il. Every moment of Kim Jong Un's life is replete with loving care and solicitude for the people," the essay said.
Wednesday's procession had a stronger military presence than in 1994.
Kim Jong Il, who ushered in a "military first" era when he took power, celebrated major occasions with lavish, meticulously choreographed parades designed to show off the nation's military might, such as the October 2010 display when he introduced his son to the world.
Associated Press Korea bureau chief Jean H. Lee and writers Hyung-jin Kim, Foster Klug, Scott McDonald and Sam Kim in Seoul, South Korea, contributed to this report. Follow AP's North Korea coverage at twitter.com/newsjean, twitter.com/APKlug and twitter.com/samkim_ap.