The shadowy star in front of you is called a "Star Marker." When you collect all 8 Red Coins, the Star will appear.
— Signpost • Super Mario 64

Star Markers are objects that appear in Super Mario 64 and its remake, Super Mario 64 DS. They serve the purpose of marking where the Power Star will appear once the player has collected all eight Red Coins in the level.