ros-industrial-consortium/descartes — pull request #25 by dpsolomon (2014-11-02 05:50:22+00:00)
Title: Initial implementation of JointTrajectoryPtDefaultSampler

DO NOT MERGE THIS PR!

This PR is for discussion only, it is not ready to be merged. Please let me know your thoghts on implementing a sampler. Some notes I already realize:
* I don't have a good way of passing data of different `TrajectoryPts` to the sampler
* If I continue on the `getData()` route, I think I should be using `const void *` at least.
* I would like associate a sampler with each `TrajectoryPt` and implement `TrajectoryPt::sample()` which calls the pt's associated sampler, but I have to resolve some issues, including how two classes can easily depend on each other (sampler would depend on pt, pt would depend on sampler. Maybe its not a big deal if they remain in one `descartes_core` library?)
* The `SamplerState` currently holds alot of data as of the `init()` call. I would like to have the `operator++` actually calculate the next sample instead of just retrieving it from an array of precalculated samples.

I have included a unit test to show how the sampler may be used. This test has exposed one pain, which is how to properly create a `TrajectoryPtPtr` (my test implementation feels hacky).