i10 / ARPen

Apache License 2.0
20 stars 13 forks source link

Use enum MarkerFace to avoid magic numbers for marker-ids #7

Closed Zaubentrucker closed 5 years ago

Zaubentrucker commented 5 years ago

I found the handling of the marker ids as Integers to be quite confusing. Especially in the long switch/case statement in calculatePenTip() , the meaning of the switch-variable is hard to grasp.

I propose to use an enum to map the marker ids to the respective faces of the marker cube.