home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / sys / next / programm / 5262 < prev    next >
Encoding:
Text File  |  1992-07-27  |  2.8 KB  |  64 lines

  1. Newsgroups: comp.sys.next.programmer
  2. Path: sparky!uunet!usc!aero.org!Aero.org!strauss
  3. From: strauss@Aero.org (Daryll Strauss)
  4. Subject: Re: lines, arcs, curves in RenderMan?
  5. Message-ID: <1992Jul27.173858.5324@aero.org>
  6. Keywords: renderman
  7. Sender: news@aero.org
  8. Organization: The Aerospace Corporation
  9. References:  <1992Jul27.013112.1645@proforma.com>
  10. Date: Mon, 27 Jul 1992 17:38:58 GMT
  11. Lines: 51
  12.  
  13. In article <1992Jul27.013112.1645@proforma.com>, jgg@proforma.com (J. G. Gregory) writes:
  14. |> I am sure I am missing something, but I open myself to abuse by asking a  
  15. |> potentially stupid question:
  16. |> 
  17. |> How do you draw lines, arcs, or other curves in the 3Dkit?
  18.  
  19. The short answer is that 2D primitives don't exist in RenderMan. 
  20.  
  21. 3D kit gives you the ability to mix PostScript and RenderMan, but only
  22. in limited ways. You can place the PostScript underneath or above the
  23. RenderMan output. For example, you can place a TIFF file as the
  24. background with a 3D object in front of it, or you can create a 3D
  25. object and annotate it with the PostScript on top. You can't have
  26. PostScript that both occludes and is occluded by the 3D object.
  27.  
  28. In a purely theoretical sense, the problem is that 2D objects are
  29. invisible in a 3D world. A line, being infinitesimally thin, doesn't
  30. render as any pixels no matter where you place the camera. PostScript
  31. has the same problem with its lines. The PostScript solution is to make
  32. zero with lines be a device dependent thickness such that they image as
  33. one pixel thick.
  34.  
  35. I suppose that RenderMan could do a similar thing by defining a bunch of
  36. 2D (lines, arcs, etc) primitives map them into curved cylinders with a
  37. device dependent thickness that would render to one pixel wide. The
  38. appropriate thickness would have to change depending on the distance the
  39. 2D object is from the camera. That might make things easier, but Pixar
  40. would essentially end up implementing all of PostScript in RenderMan. I
  41. also suspect it would really mess up your sense of depth, because your
  42. line would change size within the scene. So, I don't think it makes
  43. sense.
  44.  
  45. RenderMan is a scene description language. You provide it with the real
  46. data for the scene and it provides a rendering of that scene. You're
  47. asking for a way to mix non real objects into the scene. RenderMan
  48. doesn't support that. You could create the objects (cylinders) yourself,
  49. but that varying width would make life difficult. You could query the
  50. camera in the cylinders renderSelf method to perform a mapping from
  51. screen coordinates to world coordinate over the pixels where the
  52. cylinder will be, and then use that to set the width of the cylinder,
  53. but that's a really ugly hack. I'd suggest that if the
  54. foreground/background PostScript doesn't do what you want, then you need
  55. to rethink what you are trying to do in RenderMan.
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.  
  64.