Start coding with HTDP

HTDP is the short abbreviatio of How To Design Programs

-Intro Why and Why

I am not majored at Computer Science nor any subject which relates to programming,instead I learn most knowledge about Geography and Urban Planning/design in College.The very reason I want to start programming is I found that script plays a really important role in 3D software,computer can do nearly everything for you in your favorite 3d package if you know how to communicate with it.

The very first time I attempted to writing program is Designing a small program is to place multiple lights in the scene via bpy in blender called cube-light-distributer which looks quite naive right now.Learn Some Coding ! That's the voice in my head remind me from time to time. Right now I finally have a chance to settle down and escape from rendering/modeling work for a while.I am a newbie again in a completely different field which makes me horrible and extremely lonely,kinda like the first time I set up my mind to model an easy architecture in 3dsmax.

There are lots of scripts from varient modeling packages I love:

1.Forest Pack by Itoosoft which saves tons of time for an artist,it aims at instancing thousands/millions of vegetation automatically and the point-cloud display mode free lots of resources for users,then users can easily navigate the scene without any lag.It is welcomed by artists all over the world since early 90s and still being heavily used in Architecture Visualization industry and Gaming Industry,absolutely an industry standard.

2.Railclone by Itoosoft which instanced multiple object with Linear 1S and Array 2S function. Instead of Copy and Move the object manually,Railclone handles all the hard job for users while users still have freedom to randomize the position/rotation/scale and texture-coordinate. The most satisfying part is the Node-Based interface which makes it really easy to reuse the segment users have just finished,users can make their own macro(consists of multiple node) and share with other users.

3.Profile Builder for Sketchup is the first parametric instancing plugin in Sketchup platform aims at BIM usage. The Profile function and Assembly function is quite easy for users to grasp and immediately make something useful which could be reused in the future program.

4.Skatter for Sketchup which is kinda like Forest pack which instance object in the scene quickly,the render-only mode greatly reduce the consume of resources,making navigation in the viewport easily and I believe that Skatter greatly boost the image quality of Sketchup community.The user interface is also carefully designed,which looks quite comfortable.

5.Animation-Node in Blender,it is an addon from Jacques Luke in python.I have lots of fun playing with it,users make really cool animation easily with the help of this addon.

Writing scripts for Community artist ,help artists by saving their time means a lot to me.The last but not least,I want to do cool stuff which make lots of people happy,that's my dream. I want to stick to my dream,maybe it's too ambitious a goal for me but I found it meaningful than rendering a perfect CG image(but its really fun). That's why I start to learn and I hope this goal can keep motivating me forward.

- Where I should start

There are lots of languages: Python Ruby C++ C obj-C C# which all of them are related to 3d industry. Lots of people recommend python as the first language for a desperate rookie,the reason is: Life is short,why not python? Indeed,python is popular around the world of programmers. Python API is implemented by Rhino Blender and Maya,allowing users to customized their own script to make application more efficient and powerful.

I really want to start writing programs right now,pick up a language and dive into it,but I also understand that I will do nothing if I don't know how to write code systematically,how to design and maintain a program with lots of complicated functions. I have lots of ideas here and there,I need to find a place to start.Instead of learning SICP firstly,I decide HTDP to be a start point.

The first major problem for me is understand each sentence of this book as I am not a native English speaker.I have to deal with this book carefully.The key point of this book is about the design recipe,it is extremely important for Program Designing,here is a snippet :

1.When the problem statement distinguishes different classes of input information,you need carefully formulated data definitions.

A data definition must use distinct clauses for each sub-class of data or in some cases just individual pieces of data.Each clauses specifies a data representation for a particular sub-class information.The key is that each sub-class of data is distinct from every other class,so that our function can proceed by analyzing disjoint cases.

2.As far as the signature,purpose statement,and function header are concerned,you proceed as before

Comments
Write a Comment