The U.S. will open the Olympics against China and also will face Venezuela and Australia after being drawn Friday into what appears to be the easier men's basketball group.
The Americans will be in Group A, which will also include two teams that will be determined after three qualifying tournaments in July.
Group B includes Spain, Argentina, Lithuania, host Brazil, Nigeria and the remaining July qualifier.
The U.S., which has won the last two Olympic gold medals, is the No. 1-ranked country in the world. Spain, Lithuania and Argentina are Nos. 2-4 and Brazil is ninth.
Australia, China and Venezuela, which qualified by winning their regional zone championships, are all outside the top 10.
But the July tournaments feature strong teams such as France, Serbia and Greece, so the Americans could end up with two more strong opponents. The three six-team tournaments will be held from July 4-10, giving the winners an early start on having their teams ready for Rio.
"So we know that they'll not only be excellent teams, but they will already be on a roll when they get to the Olympics," U.S. coach Mike Krzyzewski said in a statement.
"We know that repeating as gold medalists at the 2016 Olympics will be a challenge, and that's what makes winning a gold medal such an amazing accomplishment."
The draw was conducted in Mies, Switzerland, at the headquarters of FIBA, basketball's world governing body.
The Olympic competition opens Aug. 6 and the top four teams in each pool advance to the quarterfinals.
In the women's side of the draw, the United States will play in Group B along with Canada, Senegal, Serbia and two yet-to-be-determined countries from the 2016 FIBA World Olympic Qualifying Tournament in June. Australia, Olympic host Brazil, Japan and three yet-to-be-named teams make up Group A.
"I don't think you can say that one group is stronger than the other," U.S. coach Geno Auriemma said in a statement Friday. "I think we'll have five very good opponents once we know who the last two teams are. But just looking at the three we know today, we're going to have some tough competition right off the bat. ... It doesn't really matter who we have to play, however, because if you want to win the gold medal you have to go through all of the best teams to earn that top spot."
The Americans are looking to win their sixth straight Olympic gold medal and seventh overall. They will enter the Olympics on a 41-game winning streak that dates back to the 1992 Olympics bronze-medal game in Barcelona.
Information from The Associated Press was included in this report.