Texture Standard

Re: Texture Standard
Willy Tschager Wrote:As it stands now the only think to do is adding the images for CYLINDRICAL and SPHERICAL projection methods and copy'n'paste the whole thing to the specs.

I wish that were the case, but I do not belive that it is.

There are substantial problems with the current definition of TEXMAP NEXT. Please refer to the list of code snippets here and Joshua's response here.

All of those snippets were derived from contradictory information in the specification which must be rectified in order to produce a parser. Unfortunately, the "correct" behavior Joshua specified makes the situation even murkier. Metas are ignored in some cases but not in others. NEXT can even capture geometry outside the scope of an enclosing texture, meaning nested NEXTs do not necessarily nest in their behavior (that is, they need not form a stack). This is very bad.

Also, textures absolutely should not be able to cross a STEP. Attempting to rearrange the location of the STEP as Joshua suggested is also not viable. The scoping needs to be clarified that textures automatically end at STEP, FILE, or NOFILE.

Regretfully, it is simply not possible for me to implement the specified promiscuous behavior of NEXT without throwing away my entire parser and UI. The good news is that my issues with NEXT are very much edge cases. The bad news is that defining a viable NEXT is quite difficult. Imagine a future meta command:
0 // <drawing commands>

(not really all that weird, since we're in the midst of discussing one exactly like that.)

Suppose you now want to put a MULTI-LINE-META-THAT-DRAWS-STUFF into a TEXMAP NEXT. How many lines of scope does the NEXT have?

Alas, you can't answer the question in the same way across a parser which is aware of MULTI-LINE-META-THAT-DRAWS-STUFF and one that isn't.

Travis has suggested solving this problem by making it an error (or a no-op) for any NEXT to be followed by a linetype 0. This would solve the problem, but strikes me as being rather inelegant. I personally think it would be better to completely discard NEXT. It saves a whopping one line of LDraw code, but trades it for a complicated definition and implementation.

* * * *

On a much more minor note:

The fact that nesting !: is illegal must be clarified, as nesting is a logical consequence of the wording of the current specification.

The fact that filenames containing double quotes must be escaped with a backslash needs to be added to the spec. The corollary that \ as a path separator must be escaped as \\ also needs to be added.

* * * *

Hopefully these issues can be addressed, as I am very excited about the prospect of finally getting a texture standard formalized and implemented.

« Next Oldest | Next Newest »

Messages In This Thread
Texture Standard - by Orion Pobursky - 2012-05-26, 0:16
Re: Texture Standard - by Travis Cobbs - 2012-05-26, 1:24
Re: Texture Standard - by Roland Melkert - 2012-05-28, 19:07
Re: Texture Standard - by Willy Tschager - 2012-05-28, 20:27
Re: Texture Standard - by Allen Smith - 2012-05-29, 4:33
Re: Texture Standard - by Travis Cobbs - 2012-05-29, 5:14
Re: Texture Standard - by Willy Tschager - 2012-06-11, 20:58
Re: Texture Standard - by Chris Dee - 2012-08-09, 8:56
Re: Texture Standard - by Travis Cobbs - 2012-08-10, 16:15
Re: Texture Standard - by Travis Cobbs - 2012-08-11, 4:08
Re: Texture Standard - by Willy Tschager - 2012-08-28, 13:32
Re: Texture Standard - by Roland Melkert - 2012-08-28, 16:50
Re: Texture Standard - by Willy Tschager - 2012-08-30, 12:15

Forum Jump:

Users browsing this thread: 1 Guest(s)