To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.cadOpen lugnet.cad in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 CAD / 16845
     
   
Subject: 
Re: Simple LDraw viewer code for Processing.org
Newsgroups: 
lugnet.cad
Date: 
Tue, 12 Jan 2010 07:05:52 GMT
Viewed: 
12145 times
  

In lugnet.cad, Andy Lynch wrote:
Well, in the interests of sharing, as this community does so well, here's the
basics of a simple LDraw viewer that I wrote in the Processing language about a
year and a half ago. It is by no means complete, but it will display small
models (if you edit the source to load the model, right near the beginning of
the main code... no way to pick from a listing)  Processing is so friendly that
I was able to build this basic viewer in just a week or two, then life jumped in
and took over all my time again, as usual.

There's a good chance that I tapped some people on here or on the Processing.org
forums to help with the math ack when I was working on it, so, sorry if I forget
to mention, but it's been a long time since I worked on this...

Here's the link to a little blurb about what I had written so long ago, with 2
sample images:
http://www.randommeme.com/mblog/post.cfm/ldraw-viewer-in-processing

And here's the link to the post with the download file:
http://www.randommeme.com/mblog/post.cfm/simple-ldraw-viewer-code-in-processing

About the Processing Language:
Processing runs in Java, and uses the same syntax, but (for me) it makes working
with graphics a breeze!
http://processing.org/
From the website:
Processing is an open source programming language and environment for people who
want to program images, animation, and interactions. It is used by students,
artists, designers, researchers, and hobbyists for learning, prototyping, and
production. It is created to teach fundamentals of computer programming within a
visual context and to serve as a software sketchbook and professional production
tool.

Enjoy.
-Andy Lynch

That looks very good.

I have also made an attempt to build a viewer, but it is also very limited in
what it can do (very little files if you do not wait an hour, no optional lines,
but it could read subfiles).
As I discovered that it is quite easy to write a viewer for some lines, but
much, much for effort to have a quick working LDraw viewer I left that project
and asked for a DLL from the current working LDraw viewer that I can use in my
apps.

So at present I am still searching for such a .NET DLL for a viewer that can be
used on all OS without to be recompiled.

cu
mikeheide

   
         
   
Subject: 
Re: Simple LDraw viewer code for Processing.org
Newsgroups: 
lugnet.cad
Date: 
Tue, 12 Jan 2010 11:12:33 GMT
Viewed: 
12312 times
  

In lugnet.cad, Michael Heidemann wrote:
I have also made an attempt to build a viewer, but it is also very limited in
what it can do (very little files if you do not wait an hour, no optional lines,
but it could read subfiles).
As I discovered that it is quite easy to write a viewer for some lines, but
much, much for effort to have a quick working LDraw viewer I left that project
and asked for a DLL from the current working LDraw viewer that I can use in my
apps.

So at present I am still searching for such a .NET DLL for a viewer that can be
used on all OS without to be recompiled.

cu
mikeheide
I tried to write a viewer once too (as a series of experimentation of maybe
having done a CAD program for parts authors!) using Tcl and OpenGL, but it
turned out to be *REALLY* slow, most probably due to bad subfile handling. While
the Animal Frog piece was not *so* bad, 3002.dat was incredibly slow and the PF
M-Motor threw an overflow error. So much for that. :)

Akin to Mike's hopes, an LDraw viewer library for tcl3d (=OpenGL bindings for
Tcl) would indeed work for me...

-Santeri

   
         
   
Subject: 
Re: Simple LDraw viewer code for Processing.org
Newsgroups: 
lugnet.cad
Date: 
Tue, 12 Jan 2010 13:16:13 GMT
Viewed: 
12329 times
  

In lugnet.cad, Santeri Piippo wrote:
In lugnet.cad, Michael Heidemann wrote:
I have also made an attempt to build a viewer, but it is also very limited in
what it can do (very little files if you do not wait an hour, no optional lines,
but it could read subfiles).
As I discovered that it is quite easy to write a viewer for some lines, but
much, much for effort to have a quick working LDraw viewer I left that project
and asked for a DLL from the current working LDraw viewer that I can use in my
apps.

So at present I am still searching for such a .NET DLL for a viewer that can be
used on all OS without to be recompiled.

cu
mikeheide
I tried to write a viewer once too (as a series of experimentation of maybe
having done a CAD program for parts authors!) using Tcl and OpenGL, but it
turned out to be *REALLY* slow, most probably due to bad subfile handling. While
the Animal Frog piece was not *so* bad, 3002.dat was incredibly slow and the PF
M-Motor threw an overflow error. So much for that. :)

Akin to Mike's hopes, an LDraw viewer library for tcl3d (=OpenGL bindings for
Tcl) would indeed work for me...

Incidentally, Processing does have an OpenGL renderer (JOGL), although I haven't
done any sort of testing to see how significant the performance benefit is. I
used the software renderer for the web viewer I posted just because the support
files for OpenGL increased the applet site to a few MB and I did not want to
wait for it to upload.

But, I am a fan of Tcl, too, so a tcl3d library would please me as well.

Jim

 

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