Hamlet is speaking confidentially to Horatio in Act III, Scene 2, just before the play-within-a-play is about to begin. The main purpose of Hamlet's long speech to his friend seems to be to establish that Hamlet likes and trusts Horatio so thoroughly that he has decided to tell him everything he heard from the Ghost in Act I, Scene 5. What Hamlet means when he says the lines, "Give me the man / That is not passion's slave, and I will wear him / In my heart of hearts," etc., is explained by the lines immediately preceding them.
For thou hast been
As one, in suff'ring all, that suffers nothing;
A man that Fortune's buffets and rewards
Hast ta'en with equal thanks; and blest are those
Whose blood and judgment are so well commeddled
That they are not a pipe for Fortune's finger
To sound what stop she please.
Hamlet is characterizing Horatio for the benefit of his audience as a man of strong character and sound judgment. Hamlet wants Horatio to observe the King's reaction to what is coming in the play-within-a-play because the Prince feels that he would like to have someone to verify his own observation of Claudius and his opinion of the King's behavior. Horatio is the ideal character to render a second opinion. Hamlet's wish to have his own opinion corroborated by that of another man whose intellect he respects is shown at the end of his speech.
Give him heedful note;
For I mine eyes will rivet to his face,
And after we will both our judgments join
In censure of his seeming.
This confidential meeting between Hamlet and Horatio will get Shakespeare's entire theater audience focused on the face of King Claudius, and they will all see positive proof that he is guilty and the Ghost was telling the truth. This is validated when Hamlet and Horatio meet again after Claudius has fled the performance.
O good Horatio, I'll take the ghost's word for a
Very well, my lord.
Upon the talk of the poisoning?
I did very well note him.
Evidently Hamlet really attaches great importance to verifying that what the Ghost told him was the truth. This is not just an excuse for procrastinating. One of the concerns that has kept him from assassinating the King up to this point has been his fear that the Ghost might have been the Devil in disguise and that he might be getting tricked into committing the terrible crime and sin of regicide.
After the King gives his guilt away by his horrified facial expressions and his flight from the room, Hamlet will be a changed man. His mind is relieved, and he experiences a change of character from a confused and unhappy youth to a focused and determined prince. From that point on he will have definitely decided to kill the fraudulent, illegitimate King, although he will be delayed by being sent off to England and captured by pirates.
This play-within-a-play is a stroke of genius. Shakespeare wanted Claudius himself to reveal his guilt to Hamlet as well as to the entire theater audience. Otherwise, there is nothing but hearsay evidence from the Ghost.