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 / 400
399  |  401
Subject: 
Re: Java LDraw/LDLite
Newsgroups: 
lugnet.cad.dev, lugnet.cad
Date: 
Fri, 26 Feb 1999 22:50:03 GMT
Viewed: 
1801 times
  
Sproaticus wrote:

Greg Williams wrote:
[...] or the parts would have to be downloaded on the fly over
the network.

I've though a bit about this -- I think I would prefer uncompressed
individual files, as this would make parts updates easier on the server
end.  Just copy the /P and /PARTS dirs to the Web server.  (1)

<DEVILS_ADVOCATE>
However, the JDK now has built-in support for ZIP files, so why not put the
entire parts library into a ZIP file, and cache a local copy if an app?
</DEVILS_ADVOCATE>

Yes, definitely if as an app would you have all the files locally.  I was
talking about an applet that would not.  You don't want to have to download the
entire zip file every time because it would be fairly large.  Having
individually compressed part files would decrease the amount of download.  As
far as making updates easier, that isn't an issue.  You could run a daemon to
autocompress the files in the directory, or you could compress the file as part
of the processing when a request is made.  We could even use a Java Servlet
instead of perl to process the requests.  I've had experience with those as
well, and they're faster than perl scripts in processing requests.  Heck, you
could write a Servlet to render a gif or jpeg image and return that to a web
browser without needing an applet on the client.  I don't know if that would be
too much to ask of a server, though.  Todd, what do you think of that?

- Program would be self updating on request (It could determine if an update is
available and go get it when you want.  This only makes sense for an
application, of course.)

Probably not.  You'll have a huge problem with non-standard install
directory paths, with being more than just one version out of date, etc.
etc. etc.  Better to let the user be notified of updates, and let them do it
themselves, perhaps with the aid of an external wizard.

As I said, I've already written a java program that does this.  Directory and
more than one version out of date is not an issue.  At worst it would download
and run a new install program.  When I say self updating, the user would be
notified of the update and be able to go get it any time.

- Multithreaded (This means it could be drawing one part while downloading the
next, for example.)

Another strength of using Java.  MediaTracker works well for this, though
it's optimized for images.

Don't need MediaTracker.  All you do is have a download thread, and then it
finishes downloading a needed part, it starts a draw thread on that part.

The only downside is finding enough time to do it.

Amen.

Greg, it's good to see you again.  :-,

I never really left.  I've just not had anything to say on the current
discussions.  Plus, I have been busy at work a lot lately, so time has been
limited.  :-)

<shamless plug>
BTW: my company is looking for a  java programmer.  I work for Healtheon
(http://www.healtheon.com), and my office is in Atlanta.
</shameless plug>

1.  Greg has an idea.  And the applet could be linked to the message in
cad.dat.  Todd what do you think about something like
http://www.lugnet.com/ldraw.cgi?/parts/3039.DAT ?  Your typical model might
make 1500 hits or so before it's done, though, which is another argument for
ZIP compression.

1500 hits?  No way.  Once I get a part once, I don't need to get it again.  One
hit for the model file, one for the part primitives (I would always download all
of them), and at most one for each part in the model file.  Once a part is
downloaded once, it won't need to be done again during that session.  So unless
you have 1500 unique parts in your model, you won't get nearly that many.

--
-----
Greg Williams
gregw@mindspring.com
http://www.mindspring.com/~gregw



Message has 1 Reply:
  Re: Java LDraw/LDLite
 
[removed lugnet.cad from Newsgroups line] (...) I think the speed comparison depends on whether you use mod_perl or CGI+Perl or a specialized Perl HTTP daemon. Of course, if the code running on the server is Java, a Servlet is almost certainly the (...) (26 years ago, 27-Feb-99, to lugnet.cad.dev)

Message is in Reply To:
  Re: Java LDraw/LDLite
 
(...) I've though a bit about this -- I think I would prefer uncompressed individual files, as this would make parts updates easier on the server end. Just copy the /P and /PARTS dirs to the Web server. (1) <DEVILS_ADVOCATE> However, the JDK now has (...) (26 years ago, 26-Feb-99, to lugnet.cad.dev, lugnet.cad)

51 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