Hanuman met Rama in a human form. This is due to the request of his lord Sugriva. Sugriva asked Hanuman to investigate who the warriors visiting the Rishyamooka mountain. Sugriva was frightened by the sight of Rama and Lakshmana thinking that they were sent by his brother Vali.
वालि प्रणिहितौ एव शन्के अहम् पुरुषोत्तमौ |
राजानो बहु मित्राः च विश्वासो न अत्र हि क्षमः || ४-२-२१
"I presume these two... those best of men are abetted by Vali to assault me... for, the kings like Vali do have many friends and trusting them absolutely is an unpardonable mistake... [4-2-21]
Sugriva asked Hanuman to go to them in a commoner form rather than his original form because if the two warriors (Rama and Lakshmana) were indeed sent by Vali, they would easily recognise him and know the whereabouts of Sugriva too.
तौ त्वया प्राकृतेन एव गत्वा ज्ञेयौ प्लवंगम |
इङ्गितानाम् प्रकारैः च रूपव्या भाषणेन च || ४-२-२४
Begone to them oh, monkey Hanuma, in a commoner's form, for your monkey-hood is distinguishable by Vali's agents, and know the intentions of those two by their conduct, by their semblance, and by their conversation, as well...[4-2-24]
After assuring his Lord Sugriva nothing to fear, Hanuman assumed a form an ascetic and went to the Ikshvaku brothers.
कपि रूपम् परित्यज्य हनुमान् मारुतात्मजः |
भिक्षु रूपम् ततो भेजे शठबुद्धितया कपिः || ४-३-२
Casting off his monkey's semblance Air-god's son Hanuma attained the persona of an ascetic, for that monkey is incredulous in mind about Raghava-s. [4-3-2]
The reason for choosing an ascetic, thinking that nobody tells a lie to an ascetic, and thus he wanted to gain information in an ascetic's form.
This was the first meeting between Hanuman and Sri Rama. Before this incident, there were strangers. That is the reason Hanuman asks Rama and Lakshmana a series of questions but finds no reply from them. Their conversation is given in this answer.
Neither Rama identified Hanuman nor Hanuman identified Rama.
The powers forgotten by Hanuman was his special powers given as a boon by the Gods when he was hit by the Vajra of Indra. He only forgot special powers only exclusive to him. Whereas shapeshifting is a common power to all the vanaras.
काम रूप बलोपेता यथा काम विचारिणः || १-१७-२४
सिंह शार्दूल सदृशा दर्पेण च बलेन च |
They are endowed with guise changing faculties, with bodily might and by their pride and might are identical to lions and tigers, and they are born-free in their movement in forests. [1-17-24b, 25a].
All the Vanaras also had this power. During the coronation of Sri Rama, the Vanaras changed their form into Human beings and wore ornaments.
नवनागसहस्राणि ययुरास्थाय वानराः |
मानुषन् विग्रहन् कृत्वा सर्वाभरणभूषिताः || ६-१२८-३२
Assuming human forms and adorned with all types of ornaments, monkeys sallied forth, mounting on mine thousand elephants. [Yuddha Kanda sarga 132 shloka 32]
So, he had no problem in changing his form.