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 / 1290
1289  |  1291
Subject: 
Re: Problem with L3P
Newsgroups: 
lugnet.cad
Date: 
Sat, 13 Mar 1999 04:54:46 GMT
Viewed: 
1107 times
  
On Fri, 12 Mar 1999 10:16:13 GMT, "Lars C. Hassing" <lch@ccieurope.com> wrote:

The Color7 is a "fallback" color. If no colors are defined in a model
(which then most likely is a part) POV would use a DEFAULT black
texture. I therefore used the grey (Color7) as LDraw does.

Normally this is not a problem since a model typically specifies colors
for all of its parts, and then it doesn't matter if the model object
itself is colored grey. The color settings (texture/material) for each
part overrides this. Exactly as for patterned parts, where a portion of
the part is not colored 16, but specific colors.

However, as Terry found out, it seems that there are some side effects.
I have investigated some scenarios:

First Terry's problem:
0 FILE test4073.dat
1 33  0 0 0  1 0 0  0 1 0  0 0 1 4073.dat
which L3P translates into:
#declare test4073_dot_dat = object {
object { _4073_dot_dat matrix <1,0,0,0,1,0,0,0,1,0,0,0> material {
Color33 } }
}
object { test4073_dot_dat material { Color7 } }

As you have noticed, Color7 overrides Color33.
And changing "object" to "union" in the declaration of test4073_dot_dat
will solve the problem. However, you get a warning from POV: "Should
have at least 2 objects in csg".

True.  But warning or no, changing it to "union" still works.  :-)

Unless we use hard-coloring of parts (e.g. chrome antenna),
which I generally find a bad idea.

Which is going to happen eventually.   Does it make a difference if the actual
part is _not_ hard-colored?  As in, the chrome colored part is a "shortcut"
that calls the original #16 colored part and colors it chrome?
Because that is how it will happen.

So the problem will probably only arise when trying to render a
part in another color as Terry did.

There are two possible solutions to Terry's the problem:
1) I could use POV's #default directive in stead of Color7. However,
  the #default directive only allows texture and not material (I
  wonder why?), so this will not help Terry with his trans-blue.

2) I will add an -c<color> option to let you specify the default
  drawing color. This also eliminates the need of the temporary file,
  you created only to apply a color.

Third solution:  Stop rendering single parts!  :-)

Expect 2) to appear in the forthcoming release.
/Lars

Thanks, Lars.

-- Terry K --

-----Original Message-----
From: legoverse@geocities.com [mailto:legoverse@geocities.com]
Sent: 11. marts 1999 01:45
To: lugnet.cad@lugnet.com
Subject: Problem with L3P


Lars,

I have found what appears to be a flaw in L3P.
When rendering a single piece, the renderings always come out
in a grey (#7)
color.  (1)

For instance, make a dat file containing only a single 4073
1x1 round stud.
Color it 33 for trans-blue.  Then process it with L3P.

What seems to happen is that, when processing only a single
piece, L3P writes
the #Declare line as equaling an "object" using the proper 33
color code.
But then Object line calls the declared item and gives it a
default color of
#7.

When processing _more_ than one piece, L2P writes the
#Declare line as a
"Union".   Which works properly.

Changing the single part #Declare to = union fixes the problem.
But is it proper to have a single item declared a union?

---------
#declare 1x1round_dot_dat = object {
object { _4073_dot_dat matrix <snip> matrix <snip> #if
(version >= 3.1)
material #else texture #end { Color33 } }
}

object { 1x1round_dot_dat #if (version >= 3.1) material #else
texture #end {
Color7 } }
----------
Changing that first line like so to fix:
#declare 1x1round_dot_dat = union {


-- Terry K --
(1)  Why the heck am I rendering single pieces?  :-)





Message is in Reply To:
  RE: Problem with L3P  [DAT]
 
The Color7 is a "fallback" color. If no colors are defined in a model (which then most likely is a part) POV would use a DEFAULT black texture. I therefore used the grey (Color7) as LDraw does. Normally this is not a problem since a model typically (...) (26 years ago, 12-Mar-99, to lugnet.cad)

2 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