资源描述:
《lesson-9-GC Lesson 9 - Stair Creation》由会员上传分享,免费在线阅读,更多相关内容在学术论文-天天文库。
1、GenerativeComponents101Lesson9:StairCreation(x2)Lesson9-A:Usingstepheightandlength.Ok,I’mwithya,wheredoIstart?Let’screateallourGraphVariablesfirst:1.Defineyourvariables:Graph>ManageGlobalVariables2.TostartourstepswefirstwanttocreateaseriesofLowerpoints:Point>ByCartesianC
2、oordinatesWhenwegettotheXtranslationandYtranslationwecanusetheGraphVariablescreatedabove,withinaSeriestohelpus:Glossary:Series(start,finish,increment)ASeriesisacollectionofpointsalongalineorasurface.E.g.Series(1,10,1)returns{1,2,3,4,5,6,7,8,9,10}–startsat1,endsat10andisa
3、tintervalsof1.Series(1,10,2)returns{1,3,5,7,9},Series(2,3,0.25)returns{2,2.25,2.5,2.75,3}FortheXtranslation:Series(start,finish,increment)Wewanttostartat0.0Thefinishiscalculatedusingthevariables:Stairs_NumberOfStepsxStairs_StepLength(Use*fortimes)Wewanttheincrementtobeth
4、eStairs_StepLenth.FortheYtranslationiscalculatedthesamewayusingtheHeightVariables.LetsgivethisFeatureaname-LowerPointsthatwecanrecogniseitinthefuture:Forgottogivethefeatureanameasyouwereworkingonit?JustEditthefeatureandRenameit.3.Nowletscreateourprofilelines.Line>ByStart
5、PointDirectionAndLengthLetsstartwiththeheightlines(risers).RenameyourLinefeaturetoStairs_Heights.OurstartpointisthefeatureLowerPoints.OurdirectionisfromtheBaseCSintheYdirection.OurLengthistheVariableStairs_StepHeight.Andthenourlengths(treads).RenameyourLinefeaturetoStair
6、s_Lengths.Thistimeourstartpointsaretheendpointsoftheabovelines(Stair_Heights),whichwecanwritebyStairs_Heights.EndPoint.OurdirectionisfromtheBaseCSintheXdirection.OurLengthistheVariableStairs_StepLength.4.Lastly,letshideourpoints.UsetheDisplayTool(andyouthoughtitwasdiffic
7、ult!)andpicktheelementsyouwishtohide–inthiscaseletshidethepoints.You’llnoticeintheSymbolicviewthatyourpointsgraphichasgreyedout.Howdoyouunhidesomething?UsethesametoolandpickthegreyedoutPointsgraphic.(Noticeintheexamplescriptthatwehavehiddeneverything–sowecanshowyouanothe
8、rwayofdrawingyourstairs…)Lesson9-B:Usingstairtotalheightandlength.1.Defineyourvariables:Thistimewearego