Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 08/15/2021 in all areas

  1. Sometimes we think that a drawing is correct, instead we do not realize that the lines that compose it are not perfectly horizontal / vertical or have a length with a dot (not integer). I made this lisp just to find these errors. By selecting the design, the design is recreated and the lines are colored: - Cyan Line Correct rotation and length (whole or half cm) - Green Line Rotation correct but incorrect length (2 or + decim. after dot) - Magenta Line Slightly incorrect rotation (< 1°) and correct length - Red Line Slightly wrong rotation (< 1°) and wrong length - Blue Line Rotation any (visible <> from 0-90-180-270) and length. correct - Yellow Line Rotation any and wrong length As you can see, the door and the left window have wrong lines. The roof has a blue and yellow color as the lines clearly have a rotation greater than 1 °. Verifline.mp4 PS. The design of this house is the project I made .... when I was 4 years old! ;) VERIFLINE.LSP
    1 point
  2. They had CAD when you were four, you're making me feel old! I was in my twenties when CAD first came out. To do survey calculations when I started we had a choice of either a 5 place logarithm book or a 7 place one, either could be interpolated two more places. I didn't think it could ever get better when Texas Instruments first released a calculator with trig functions on it.
    1 point
  3. Just to add to the general mayhem caused by second guessing the OP's intentions, the distance between the geographical coordinates (latitude and longitude) and the text insertion point is about 11 miles (assuming the coordinates were UTM zone 44Q). However it might be Indian Zone IIIA. Who knows?
    1 point
  4. 1 point
  5. Have a look at my code it checks which end did you pick, so the extra pick a side as it appears you only want 1 end. Other way is a left or right prompt. Look at the polar in the code where it works out the new end point. Using a vla-getclosestpointto - pick point will give the angle direction. Inclined lines ok. (Setvar 'filletrad 0.0) so its a chamfer. Have a go if stuck post.
    1 point
  6. I understand was just posting what Tombu was saying
    1 point
  7. That's actually an interesting one, and I'm quite surprised that there's no solution in Google anywhere for AutoLISP. Let me be the first then: ;; JH:RGB->HEX --> Jonathan Handojo ;; Converts an RGB to HEX in the form of a string (defun JH:RGB->HEX (r g b) (apply 'strcat (mapcar '(lambda (x / h) (if (< (strlen (setq h (JH:numhex x))) 2) (strcat "0" h) h)) (list r g b))) ) ;; JH:numhex --> Jonathan Handojo ;; Converts an integer to a hex number in the form of a string (defun JH:numhex (num / hex) (setq hex (mapcar 'cons '(10 11 12 13 14 15) (mapcar 'chr '(65 66 67 68 69 70)))) (apply 'strcat ((lambda (x / l h) (if (zerop x) '("0") (progn (while (/= x 0) (setq l (cons (cond ((cdr (assoc (setq h (rem x 16)) hex))) ((itoa h))) l) x (/ x 16) ) ) l ) ) ) num ) ) ) I'm sure someone has a better approach. _$ (JH:RGB->HEX 45 89 142) "2D598E"
    1 point
×
×
  • Create New...