For hundreds of years Christians have interpreted Peter's vision as God's permission to kill and eat any animal, which it is not. It is a vision to let Peter know that he and other Jewish-Christians were permitted to enter the homes of the Gentiles to bring them the Good News of Jesus Christ.
Let's take a look at this passage in more detail.
Setting the stage:
1 There was a certain man in Caesarea called Cornelius, a centurion of the band called the Italian band,
2 A devout man, and one that feared God with all his house, which gave much alms to the people, and prayed to God always.
It is important for us to understand that God truly hears the prayers and sees the intent of the heart of all people, even if they are not Jews or Christians; and in His grace, He reaches out to them as he is doing here with Cornelius.
3 He saw in a vision evidently about the ninth hour of the day an angel of God coming in to him, and saying unto him, Cornelius.
4 And when he looked on him, he was afraid, and said, What is it, Lord? And he said unto him, Thy prayers and thine alms are come up for a memorial before God.
5 And now send men to Joppa, and call for one Simon, whose surname is Peter:
6 He lodgeth with one Simon a tanner, whose house is by the sea side: he shall tell thee what thou oughtest to do.
7 And when the angel which spake unto Cornelius was departed, he called two of his household servants, and a devout soldier of them that waited on him continually;
8 And when he had declared all these things unto them, he sent them to Joppa.
Cornelius listened to the angel of God, but now the Lord must prepare the heart of Peter to go back with the men that he sent to Joppa, for the Jews had a tradition that they would not enter the home of a non-Jew, for to enter would somehow contaminate them or make them unclean.
F. F. Bruce writes,
But Peter must be prepared for the interview as well as Cornelius, and there were scruples to be overcome on Peter's side as there were not on Cornelius's. A God-fearer had no objection to the society of the Jews, but even a moderately orthodox Jew would not willingly enter the dwelling of a Gentile, God-fearer though he were. No doubt some of Peter's inherited prejudices were wearing thin by this time, but a special revelation was necessary to make him consent to visit a Gentile.
9 On the morrow, as they went on their journey, and drew nigh unto the city, Peter went up upon the housetop to pray about the sixth hour:
10 And he became very hungry, and would have eaten: but while they made ready, he fell into a trance,
11 And saw heaven opened, and a certain vessel descending unto him, as it had been a great sheet knit at the four corners, and let down to the earth:
12 Wherein were all manner of fourfooted beasts of the earth, and wild beasts, and creeping things, and fowls of the air.
13 And there came a voice to him, Rise, Peter; kill, and eat.
14 But Peter said, Not so, Lord; for I have never eaten any thing that is common or unclean.
15 And the voice spake unto him again the second time, What God hath cleansed, that call not thou common.
16 This was done thrice: and the vessel was received up again into heaven.
God had used the Jewish dietary laws to bring the point home to Peter, and Peter never gave in to the temptation, even though the Lord had said that what He had cleansed would no longer be considered unclean.
Peter knew that God would not change His word or the Law. He might explain it or show it's true meaning as Jesus often did, but Peter knew that the Lord would not abolish the Law - there must be another explanation.
There is also a good possiblilty, that Peter knew and remembered the story of the Rechabites who refused to drink the wine that Jeremiah had offered them according to the instructions of the Lord, and how the Lord used this as a testimony against the men of Judah (Jeremiah 35:1-19). These Rechabites didn't give into the temptation of the Lord, and neither did Peter.
The meaning of the vision:
17 Now while Peter doubted in himself what this vision which he had seen should mean, behold, the men which were sent from Cornelius had made inquiry for Simon's house, and stood before the gate,
18 And called, and asked whether Simon, which was surnamed Peter, were lodged there.
19 While Peter thought on the vision, the Spirit said unto him, Behold, three men seek thee.
20 Arise therefore, and get thee down, and go with them, doubting nothing: for I have sent them.
21 Then Peter went down to the men which were sent unto him from Cornelius; and said, Behold, I am he whom ye seek: what is the cause wherefore ye are come?
22 And they said, Cornelius the centurion, a just man, and one that feareth God, and of good report among all the nation of the Jews, was warned from God by an holy angel to send for thee into his house, and to hear words of thee.
The vision had nothing to do with the mission God had given Peter. The vision was only to attract Peter's attention. Peter knew that he was not to kill and eat the animals that were upon the sheet. He knew that God was only testing him. And now he knew, or at least highly suspected that the test was about the salvation of the Gentiles. God was not cleansing unclean animals and making them clean. He was showing Peter that he was about to cleanse the hearts of the people whom the Jews considered to be unclean.
God's timing is always perfect. Just as Peter was wondering about the true meaning of the vision, the Gentiles show up at Simon's home.
Peter goes to Cornelius:
23 Then called he them in, and lodged them. And on the morrow Peter went away with them, and certain brethren from Joppa accompanied him.
The very fact that Peter invited them into Simon's home is further proof that Peter truly understood the meaning of the vision, and that it had nothing to do with food, but only about the salvation of the Gentiles. And we have even greater proof that Peter understood the true meaning of the vision, for he freely entered the home of Cornelius.
24 And the morrow after they entered into Caesarea. And Cornelius waited for them, and had called together his kinsmen and near friends.
25 And as Peter was coming in, Cornelius met him, and fell down at his feet, and worshipped him.
26 But Peter took him up, saying, Stand up; I myself also am a man.
27 And as he talked with him, he went in, and found many that were come together.
28 And he said unto them, Ye know how that it is an unlawful thing for a man that is a Jew to keep company, or come unto one of another nation; but God hath shewed me that I should not call any man common or unclean.
This is proof that Peter understood the true meaning of God's vision.
29 Therefore came I unto you without gainsaying, as soon as I was sent for: I ask therefore for what intent ye have sent for me?
30 And Cornelius said, Four days ago I was fasting until this hour; and at the ninth hour I prayed in my house, and, behold, a man stood before me in bright clothing,
31 And said, Cornelius, thy prayer is heard, and thine alms are had in remembrance in the sight of God.
32 Send therefore to Joppa, and call hither Simon, whose surname is Peter; he is lodged in the house of one Simon a tanner by the sea side: who, when he cometh, shall speak unto thee.
33 Immediately therefore I sent to thee; and thou hast well done that thou art come. Now therefore are we all here present before God, to hear all things that are commanded thee of God.
Peter begins to preach the Good News:
34 Then Peter opened his mouth, and said, Of a truth I perceive that God is no respecter of persons:
35 But in every nation he that feareth him, and worketh righteousness, is accepted with him.
This is the true meaning of the Lord's vision to Peter, and Peter is letting these Gentiles know that God has cleansed that which separated the Jews from the Gentiles, and that cleansing came through the blood of Jesus Christ.
36 The word which God sent unto the children of Israel, preaching peace by Jesus Christ: (he is Lord of all:)
37 That word, I say, ye know, which was published throughout all Judaea, and began from Galilee, after the baptism which John preached;
38 How God anointed Jesus of Nazareth with the Holy Ghost and with power: who went about doing good, and healing all that were oppressed of the devil; for God was with him.
39 And we are witnesses of all things which he did both in the land of the Jews, and in Jerusalem; whom they slew and hanged on a tree:
40 Him God raised up the third day, and shewed him openly;
41 Not to all the people, but unto witnesses chosen before of God, even to us, who did eat and drink with him after he rose from the dead.
42 And he commanded us to preach unto the people, and to testify that it is he which was ordained of God to be the Judge of quick and dead.
43 To him give all the prophets witness, that through his name whosoever believeth in him shall receive remission of sins.
44 While Peter yet spake these words, the Holy Ghost fell on all them which heard the word.
45 And they of the circumcision which believed were astonished, as many as came with Peter, because that on the Gentiles also was poured out the gift of the Holy Ghost.
46 For they heard them speak with tongues, and magnify God. Then answered Peter,
47 Can any man forbid water, that these should not be baptized, which have received the Holy Ghost as well as we?
48 And he commanded them to be baptized in the name of the Lord. Then prayed they him to tarry certain days.
And just in case that Peter or any of the Jews who accompanied him might still have some doubt, the Holy Spirit comfirms that salvation has indeed come to the Gentiles, for He has cleansed them and made them acceptable unto Him, because they believed in the only begotten Son of God, Jesus Christ.
Others hear of the salvation of Cornelius and his whole household:
1 And the apostles and brethren that were in Judaea heard that the Gentiles had also received the word of God.
2 And when Peter was come up to Jerusalem, they that were of the circumcision contended with him,
3 Saying, Thou wentest in to men uncircumcised, and didst eat with them.
This is why God gave the vision to Peter. He knew that others, such as these men would doubt and question, and He knew that Peter would tie the two occurrences together for the glory of God, that others would continue to bring the Good News of Jesus Christ to the Gentiles.
Again, this has nothing to do with killing and eating unclean animals or flesh of any kind. And I'm fairly certain that Cornelius knew enough about the Jewish Dietary Laws not to offend Peter and his companions by offering them food that was not considered to be in accordance with those laws. He most likely served them plant foods, which would not violate any of the dietary restrictions.
4 But Peter rehearsed the matter from the beginning, and expounded it by order unto them, saying,
5 I was in the city of Joppa praying: and in a trance I saw a vision, A certain vessel descend, as it had been a great sheet, let down from heaven by four corners; and it came even to me:
6 Upon the which when I had fastened mine eyes, I considered, and saw fourfooted beasts of the earth, and wild beasts, and creeping things, and fowls of the air.
7 And I heard a voice saying unto me, Arise, Peter; slay and eat.
8 But I said, Not so, Lord: for nothing common or unclean hath at any time entered into my mouth.
9 But the voice answered me again from heaven, What God hath cleansed, that call not thou common.
10 And this was done three times: and all were drawn up again into heaven.
11 And, behold, immediately there were three men already come unto the house where I was, sent from Caesarea unto me.
Peter understood God's message to him.
12 And the spirit bade me go with them, nothing doubting. Moreover these six brethren accompanied me, and we entered into the man's house:
13 And he shewed us how he had seen an angel in his house, which stood and said unto him, Send men to Joppa, and call for Simon, whose surname is Peter;
14 Who shall tell thee words, whereby thou and all thy house shall be saved.
15 And as I began to speak, the Holy Ghost fell on them, as on us at the beginning.
16 Then remembered I the word of the Lord, how that he said, John indeed baptized with water; but ye shall be baptized with the Holy Ghost.
17 Forasmuch then as God gave them the like gift as he did unto us, who believed on the Lord Jesus Christ; what was I, that I could withstand God?
18 When they heard these things, they held their peace, and glorified God, saying, Then hath God also to the Gentiles granted repentance unto life. (KJV)
The eating of flesh has always been a concession (Genesis 9:1-4). It never was God's intent (Genesis 1:29-30). But salvation is always greater than food or tradition, and thus through the vision of unclean animals, God showed Peter how He was about to cleanse unclean Gentiles and make them into His chosen people, just as He had done with the Jews.
 Bruce, F. F., The New International Commentary on the New Testament - Commentary on the Book of the Acts, Grand Rapids, Wm. B. Eerdmans Publishing Co., Reprinted, June 1984, 217