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 / 8767
8766  |  8768
Subject: 
Re: Ldraw DLL - Was: Ldglite must be faster
Newsgroups: 
lugnet.cad
Date: 
Thu, 3 Oct 2002 03:30:55 GMT
Viewed: 
1098 times
  
In lugnet.cad, Don Heyse wrote:

I'm not sure why, but this popped into my head last night.  I think
perhaps it may not be all that hard to do.  The basic ingredients are
already there in the winOffScreenStart() function of ldglite.  I'd just
have to convert it to use the hDC passed to it instead of creating
one with a DIB.  I just might attempt this as a learning experience
since I don't think I've ever created a DLL before.

I haven't looked at WinHandles in awhile, I don't have a strong
preference for which way we go.  Of course, if we choose right, we'll
get some drawing parameters 'for free' -- I'm thinking (trying to
remember) of window size, user-defined window dimensions.  With that
information, the DLL could draw to the size of what's available.

So, what sort of "flavor" were you thinking about for the sLDrawCode
parameter?

I was thinking it should be LDraw graphics description language code --
the stuff you see in a DAT/LDR/MPD.  At the highest level (ie, a program
is making a call to render a file), the sLDrawCode would be a single
line:
   1 <color> <position> <scale/orientation> <file>
That covers the -c -o -a and -s parameters to LDraw.

But sLDrawCode would be an arbitrarily-long chunk of LDraw code.

Should this perhaps be two parameters?  A dat file line
string and a rendering options string the like what you'd get on the
ldglite command line?

That would probably be a good idea.  More straightforward than stuffing
commandline options into the code buffer.

Or could the command line options be tacked on
at the end of the ldraw line to make it one string.  That way you could
skip the options if you want the default projection, lighting, line
size and quality, etc.

More likely, use a 0 CMDLINE meta-statement at the beginning of the
sLDrawCode buffer to indicate the desired rendering options.  But having
a separate parameter (sRenderOptions?) would be simpler.

I'm very excited - my son was asking me just last night if there was a
ActiveX control for LDrawing.  He figured someone musta done it by now.
With a DLL, he could learn how to use API calls. :)

Steve



Message is in Reply To:
  Ldraw DLL - Was: Ldglite must be faster
 
(...) I'm not sure why, but this popped into my head last night. I think perhaps it may not be all that hard to do. The basic ingredients are already there in the winOffScreenStart() function of ldglite. I'd just have to convert it to use the hDC (...) (22 years ago, 1-Oct-02, to lugnet.cad)

39 Messages in This Thread:















Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

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