Have you ever seen those pictures where lights would just beam with light rays? As an example, I've posted a picture to the left. The lamp post on the left was made into a bright looking "sunstar". It was not done by Photoshop, but just an adjustment in your aperture settings.
So to do this, I'm going to recommend shooting in manual, and on a tripod. I guess you can shoot in aperture priority mode if you need to, but make sure you meter for the light correctly. When I took these shots, I just shot with trial and error using bulb and a wired remote. These shots obviously work best at night where there are lights, and so that it stands out more. All you have to do is shoot at about f/16 or smaller. Of course it depends on your lens and the focal length so play around. The smaller your aperture gets the more defined and longer your rays should get.
Now another thing, is how many rays actually beam out of the sunstar. This is determined by how many aperture/diaphragm blades your lens has. The number of aperture or diaphragm blades multiplied by two will tell you how many rays your sunstars will have. In my example by Tamron 17-50mm f/2.8 lens has 7 blades, creating a star with 14 rays.
Have fun with this fun little trick. Make sure to bring your tripod, as some of these shots were over 20 seconds long.










