When placing sprinkles in the raw cake batter to be baked, they will melt from the residual heat. However, they will still leave a "stain" of color in the batter which will look like color flecks. This is how you can create a confetti cake.