I've sat in traffic court in the past and I noticed that most defendants simply plead guilty and are assessed the fine. Consequently, I've noticed that some defendants contest the charge and if they are unsuccessful, they are assessed both a fine and court costs, sort of a double whammy for having the audacity to fight the charge.
I've done a little bit of googling, but didn't really find anything that specifies the criteria by which a traffic court can assess court costs. The absence of results makes me think this might not be determined on the state level. Is this instead determined at the municipal level? If so, is there any guiding criteria for it?