You raise some valid points (no pun intended) and suggestions and I appreciate them. Yes, your correct in your second example that you'd have to "cap" the end of the cube if you want a 6 sided closed cube. It's ambiguous when we did wire frame stuff. I think, in a nutshell your asking if you can be defining more than one polygon at a time. This is not a bad idea for efficiency purposes but does make things a bit more complicated and I'm trying as much as possible to keep things simple. Internally the vertices are not shared so it does not make rendering any more efficient. I think your second example which includes code for capping the ends is much easier to follow. Your also right about pu, pd, it's a magic pen :-) A beta is coming soon. Andrzej B. wrote: > > Dear George > > The forecast of the new 3D turtle graphics with hidden line removal and light source effect is the best news on Logo list recently. I just start waiting for MSWLogo 6.3 (George, have You any Beta version available to download now?). > But putting this information in Logo list gives me opportunity to share with You with the following, may be stupid, concept: > Every edge in 3D environment usually belongs to two (or more) polygons. To define both polygons with "polystart" and "polyend" Logo programmer has to pass each edge twice. Shouldn't be good to mark vectors as belonging to both polygons at once? > Let's have three procedures > polystart <polygon_number> > polyon <polygon_number> > polyoff <polygon_number> > and one procedure "polyview" without parameter. > > Polystart with polygon number allows defining more then one polygon at once. Repeating polystart with the same number implies ending of a previous one, such as "polyview" implies ending of all polygons. > All vectors passed between polyon and polyoff with the same polygon number belongs to the same polygon. > > For example, with an empty cube defined as follows: > > to e_cube :a > repeat 4 [~ > fd :a down 90 > fd :a down 90 > fd :a down 90 > fd :a down 90 > fd :a rt 90 > ] > end > > a solid cube would be > > to s_cube :a > polystart 2 > polystart 3 > repeat 4 [~ > polystart 1 > polyon 1 > polyon 2 > fd :a down 90 > polyoff 2 > fd :a down 90 > polyon 3 > fd :a down 90 > polyoff 3 > fd :a down 90 > polyoff 1 > fd :a rt 90 > ] > polyview > end > > There are no supplementary vectors in the procedure above to define the top and bottom square as a polygon. > With no-parameter polystart / polyend these two squares should be explicitly added (am I wrong?): > > to s2_cube :a > repeat 4 [~ > polystart > fd :a down 90 > fd :a down 90 > fd :a down 90 > fd :a down 90 > polyend > fd :a rt 90 > ] > polystart > repeat 4 [fd :a rt 90] > polyend > down 90 fd :a up 90 > polystart > repeat 4 [fd :a rt 90] > polyend > polyview > end > > Now I am not sure, which procedure is better, but I think it would be nice to have both opportunities. > > The second little thing I'd like to touch is "pendown" and "penup". When going to 3D these two procedure names are losing their sense and starting to be misleading. I do know their historical roots, but a young Logo programmer who enters a world of 3D drawings may ask "what is a connection between turtle "up" and "down" command and "penup" / "pendown"? > I agree, a solution may be like this: > > to with.trace > pd > end > > to without.trace > pu > end > > (and forget about pd and pu) > but Logo was always a model of good naming conventions with a clear meanings so I feel pain when we lose this property. > > Best regards, > Andrzej B., Lodz Poland > > --------------------------------------------------------------- > Please post messages to the Logo forum to logo-l@gsn.org. Mail > questions about the list administration to logofdn@gsn.org. To > unsubscribe send unsubscribe logo-l to majordomo@gsn.org. -- =============================================================== George Mills (mills@softronix.com) http://www.softronix.com/ The www page contains some very powerful educational software. Our single most important investment is our kids. --------------------------------------------------------------- Please post messages to the Logo forum to logo-l@gsn.org. Mail questions about the list administration to logofdn@gsn.org. To unsubscribe send unsubscribe logo-l to majordomo@gsn.org.
Global SchoolNet Foundation -
Linking Kids Around the World!
Copyright GSN - All Rights Reserved
- Comments
& Questions
Visit GSN's
Global
Schoolhouse for more exciting learning resources!
Search our Site
-
Home