Skip to content

Commit

Permalink
[euscollada/src/euscollada-robot*.l] Always make pqpmodel for detaile…
Browse files Browse the repository at this point in the history
…d shape according to euslisp/jskeus#232
  • Loading branch information
snozawa committed Jul 17, 2015
1 parent 06e8d8d commit 27d97aa
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 30 deletions.
27 changes: 12 additions & 15 deletions euscollada/src/euscollada-robot.l
Original file line number Diff line number Diff line change
Expand Up @@ -63,21 +63,18 @@
(:make-collision-model-for-links
(&key (fat 0) (collision-func 'pqp-collision-check) ((:links ls) (send self :links)))
(dolist (ll ls)
(unless (send ll :get (read-from-string (format nil ":~Amodel"
(string-right-trim "-COLLISION-CHECK" (string collision-func)))))
(send ll
(read-from-string
(format nil ":make-~Amodel"
(string-right-trim "-COLLISION-CHECK" (string collision-func))))
:fat fat
:faces (flatten (mapcar #'(lambda (x)
(cond
((find-method x :def-gl-vertices)
(send (x . glvertices) :convert-to-faces :wrt :world))
(t
(send x :faces))))
(send ll :bodies)))))
)
(send ll
(read-from-string
(format nil ":make-~Amodel"
(string-right-trim "-COLLISION-CHECK" (string collision-func))))
:fat fat
:faces (flatten (mapcar #'(lambda (x)
(cond
((find-method x :def-gl-vertices)
(send (x . glvertices) :convert-to-faces :wrt :world))
(t
(send x :faces))))
(send ll :bodies)))))
)
)

Expand Down
27 changes: 12 additions & 15 deletions euscollada/src/euscollada-robot_urdfmodel.l
Original file line number Diff line number Diff line change
Expand Up @@ -52,21 +52,18 @@
(:make-collision-model-for-links
(&key (fat 0) (collision-func 'pqp-collision-check) ((:links ls) (send self :links)))
(dolist (ll ls)
(unless (send ll :get (read-from-string (format nil ":~Amodel"
(string-right-trim "-COLLISION-CHECK" (string collision-func)))))
(send ll
(read-from-string
(format nil ":make-~Amodel"
(string-right-trim "-COLLISION-CHECK" (string collision-func))))
:fat fat
:faces (flatten (mapcar #'(lambda (x)
(cond
((find-method x :def-gl-vertices)
(send (x . glvertices) :convert-to-faces :wrt :world))
(t
(send x :faces))))
(send ll :bodies)))))
)
(send ll
(read-from-string
(format nil ":make-~Amodel"
(string-right-trim "-COLLISION-CHECK" (string collision-func))))
:fat fat
:faces (flatten (mapcar #'(lambda (x)
(cond
((find-method x :def-gl-vertices)
(send (x . glvertices) :convert-to-faces :wrt :world))
(t
(send x :faces))))
(send ll :bodies)))))
)
)

Expand Down

0 comments on commit 27d97aa

Please sign in to comment.