Other than attempting to estimate whether a chainring or cog is worn and needs replaced by eyballing it, is there any way to measure the wear on chainrings or cassette cogs so you can determine whether they should be replaced? What tools can be used to accomplish this?
There are tools for measuring cassette wear.
And of course there is visual inspection and also how it rides / indexes, particularly under heavy load (when it will usually slip if worn).
Because there exist so many cassette styles and tooth profiles, no universal tool for measuring cassette wear exists.
One good advice to assist visual inspection is this. We all have our favorite speeds. Compare the most worn 2-3 cogs with the rest. If their profile is very different, the cassete is probably worn. The video documents how to do that.
There are many variables in determining whether you have a worn chainring or cassette. Visual inspection helps and noting the kilometres racked up should also help.
If you have set up your mech's correctly you will know you have wear when your chain starts to skip, especially under load. Visual inspection should then confirm your wear.
Park Tools do a CHAIN wear tool [CC-2] but that will not determine cassette or chainring wear. When replacing a cassette you should always replace the chain. Worn chains will reduce the life of cassettes and chainrings considerable due to the chain being worn to the form of the previous cassette/chainring.
Here is a video of the pro's confirming the above: