To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.cad.devOpen lugnet.cad.dev in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 CAD / Development / 1176
1175  |  1177
Subject: 
Re: Dimensions of the parts
Newsgroups: 
lugnet.cad.dev
Date: 
Mon, 12 Apr 1999 17:14:33 GMT
Viewed: 
822 times
  
Leonardo Zide skrev i meddelandet
<3711E2FA.17EB08D@centroin.com.br>...
Hi,

I've been trying to add collision detection to LeoCAD but I'm stuck
with a problem and would like to know if anyone has a good solution.
Take for example 2 1x1 bricks and position them side by side, they
will always be touching each other because their sizes are rounded up
(they should be about 0.01 cm less). Can anyone think of a solution • to
this ? Just don't tell me to resize all parts by hand. :)

Leonardo


- Scale the piece dimensions by 0.9 or something like that for
  comparisons - remember to use a _central_ point as origin
  for the scaling (hmm, sounds like heavy work...)

- Easier: Scale the positions with 1.01 before doing the
  comparison. Should be feasible, and not too much math.
  No need for modified origins either.

- Just don't include equality (=) in your collision test! (?)
  BTW, what is the minimum increment you can move/turn a piece?


--
Anders Isaksson, Sweden
BlockCAD:  http://user.tninet.se/~hbh828t/proglego.htm
Gallery:   http://user.tninet.se/~hbh828t/gallery.htm



Message has 2 Replies:
  Re: Dimensions of the parts
 
(...) These only work for convex pieces. The hollow areas in a concave piece would not be handled properly, since at least one wall would actually move *closer* to the other piece. For example, consider a clip. If you scale its position by 1.01, the (...) (26 years ago, 12-Apr-99, to lugnet.cad.dev)
  Re: Dimensions of the parts
 
(...) If you turn snapping off, it's 0.01 cm or 1 degree but you can set any value using a dialog box. Leonardo (26 years ago, 13-Apr-99, to lugnet.cad.dev)

Message is in Reply To:
  Dimensions of the parts
 
Hi, I've been trying to add collision detection to LeoCAD but I'm stuck with a problem and would like to know if anyone has a good solution. Take for example 2 1x1 bricks and position them side by side, they will always be touching each other (...) (26 years ago, 12-Apr-99, to lugnet.cad.dev)

14 Messages in This Thread:






Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact

This Message and its Replies on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR