TheSwamp

Code Red => AutoLISP (Vanilla / Visual) => Topic started by: mailmaverick on January 16, 2017, 02:30:30 AM

Title: Text to Speech
Post by: mailmaverick on January 16, 2017, 02:30:30 AM
I came across a nice routine for converting Text to Speech in AuTOCAD :-

Code: [Select]
(defun TexttoSpeech (str)
  ;; Text to Speech
  ;; Source : http://forums.autodesk.com/t5/autocad-civil-3d-forum/extract-and-export-surface-contours-and-labels/td-p/3013632
  (vl-load-com)
  (setq sapi (vlax-create-object "Sapi.SpVoice"))
  (vlax-invoke sapi "Speak" str 0)
  (vlax-release-object sapi)
)
(defun c:test () (TexttoSpeech "Hello ....... ") (princ))
Title: Re: Text to Speech
Post by: Marc'Antonio Alessi on January 16, 2017, 02:47:47 AM
more info: https://www.theswamp.org/index.php?topic=14549.msg542145#msg542145   :-)
Title: Re: Text to Speech
Post by: Grrr1337 on January 16, 2017, 11:29:44 AM
Nice!
 Thanks for sharing guys! 8)