[Erlang 0017]Erlang/OTP基礎模組 proc_lib

  大家好,今天周六,繼續接著上一篇,跟大家分享mochiweb源碼。上一篇,最後我們看到了mochiweb_socket_server:listen/3函數:listen(Port, Opts, State=#mochiweb_socket_server{ssl=Ssl, ssl_opts=SslOpts}) -> case mochiweb_socket:listen(Ssl, Port, Opts, SslOpts) of {ok, Listen} ->

視窗選擇資料。

 gw.getWinSizeX()611 --拾取當前視窗返回的值。1230gw.getWinSizeY()396800--根據box2  拾取視窗節點,這個很是有用。ui =boxPickNode (box2 [0,0] [1000,1000]) #($Sphere:Sphere01 @ [45.523499,34.512344,0.000000], $Sphere:Sphere02 @ [12.353422,22.442947,0.000000], $Sphere:Sphere03 @ [-

k 動畫指令碼很有演算法 同時可以借鑒這裡的畫圓

-- open the Lots of Robots tutorial file bounce.max Myobj = $Box001slidertime = 0deletekeys Myobj.pos.controllerMyobj.pos = [0,0,0]deletekeys Myobj[3][2][3].controllerMyobj[3][2][3].value = 0NowTime = 0for i = 0 to 10  do ( animate on at time

設計模式—代理模式

/** * @author Rollen-Holt 設計模式之 代理模式 */interface NetWork{public abstract void browser();}/** * Real 類代表使用者上網的實際動作,比如查看網頁 * */class Real implements NetWork{public void browser(){System.out.println("上網瀏覽資訊");}}/** * 此處使用代理類來完成中間代理的工作,屏蔽實現代理的細節 *

常用指令碼資料詞彙

角度轉弧度degto rad  隨即地取值random maselect $shapsmacroScript Macro112 category:"DragAndDrop" ( max hide command panel toggle)$box01.vertexticks=on 顯示定點標記。curvelength $ 判斷線的長度、判斷語句。。if then elese  for i in  do    while do 時迴圈語句exit 退出語句、for a in selection

大數的四則運算

    在處理大數的運算時,一般採用數組去類比,下面介紹大數的加、減、乘、除四則運算的實現方法。1.加法。  如:  Input: 123456789123456789123456789            1  Output:123456789123456789123456790  輸入採用字元數組儲存,然後將輸入存在整形數組裡,然後逐位相加即可,同時注意進位處理。#include<stdio.h>#include<string.h>int max(int

介面控制,

   try ( destroydialog gt_unnamedRollout) catch ()rollout gt_unnamedRollout "多維材質工具," width:208 height:568(    local bm = bitmap 50 50 color:red button name_but "清除沒有材質的通道並選擇面" pos:[8,60] width:192 height:24  imgTag  bmp1 "Bitmap" pos:[8,8] width:192

介面資料 用的是內部數子外部字元顯示,計算時還是用數字因為數字不字元快

 try(destroyDialog gt_yc_Ail)catch()rollout gt_yc_Ail "yongchao-對齊" width:168 height:80( spinner conunt_spn1 "" pos:[152,25] width:12 height:16  range:[1,6,1] type:#integer edittext conunt_edt1 "" pos:[3,25] width:147 height:16 text:"Z軸的負方向" enabled:

整數劃分問題(續)

     在前面已經提到了整數劃分的問題,在那個問題中,只需要求出整數劃分的個數,如果要求將整數劃分的所有劃分方法也輸出,該如何求解?如對於整數6,輸出的結果就應該是:     6     5+1     4+2   4+1+1     3+3   3+2+1  3+1+1     2+2+2 2+2+1+1 2+1+1+1+1     1+1+1+1+1+1    我們可以採用集合的思維去考慮,比如對於整數6,則初始集合相當於{1,1,1,1,1,1} 從1+1+1+1+1+1到2+1+1+

轉 指令碼調用標準材質,多維材質固有色的bulr

--調所有stadard固有貼圖blur--BY 飛浪--2008-08-12--更多指令碼盡在CG++:http://www.cgplusplus.com/bbstry destroydialog fl_defaultBlur catch()rollout fl_defaultBlur "調所有stadard固有貼圖blur" width:162 height:31( spinner spn1 "Blur:" pos:[20,7] width:67 height:16 range:[0,100

自動對齊中的一段代碼。

 distance_d =   distance  $selection[1].pos  compare_array[1].pos   try ( distance_c =   distance  $selection[1].pos  compare_array[2].pos )  catch ( distance_c =distance_d+20)    if amin distance_d  distance_c == distance_d then     (     return

[Erlang 0016]Erlang三則之 HIPE SASL Monitor

 Erlang 使用HIPE SASL Monitor常用的一些參數和命令,記錄於此備忘.  編譯啟用HIPE(High Performance Erlang) Hipe是什麼?霸爺有一個一語中的的描述"erlang的hipe相當於jit, 根據語言評測有hipe支援在純erlang的運算上會快2-3倍,這個效能的提升對於計算密集型的應用還是比較可觀的。"維基百科上關於Jit的資料:即時編譯(Just-in-time compilation),又稱為動態翻譯,是一種提高程式運行效率的方法。通常,

觸角指令碼 在新浪中 他媽的 自動的改東西。

rollout rollTentacle "Tentacles"( spinner UInBones "Number of Bones:" type:#integer range:[0,99999,5] spinner UIBonesLength "Bones Length:" type:#float range:[0,9999,30] button UICreate "Create" on UICreate pressed do (  undo on  (  punto=point() 

寫的一些指令碼思路。針對於CGlobal (觀看後的想法)

---看到別人的東西是根據選擇體的線,選擇相應的體中的線。--1.選擇線判斷兩點距離。其實這我也就明白了容差在這裡到底是什麼意思。---、--2.把模型的所有點找到。做遞迴的兩點距離判斷。 在容差範圍內的,看看是否能還原出線。如果不行就沒事。如果行就加到數組中--3.進行選擇。--4. 關與線的方式我想不出來什麼 我覺得就是遞增判斷距離。---如果是面要是多變的面怎麼著,我著面有些懸念。-----還有一個就是隨機的選擇面熟----這個思路相對明確一些,判斷是不是 poly mrsh 到面層級--

滑鼠pos 視圖的尺寸

mouse.posmouse.screenpos A read only variable to get the mouse position on the screen as a <point2> value. The coordinates are in pixel values relative to the top-left corner of the screen screenposgw.getWinSizeX() --視口的xgw.getWinSizeY()

[Erlang 0015]Erlang OTP設計原則

  閱讀Erlang官方文檔經常可以讀到下面兩句:  "xxx implemented using this module will have astandard set of interface functions and include  functionality for tracing anderror reporting. It will also fit into an OTP supervision tree. Refer to OTPDesign Principles for

改寫成畫圓演算法 畫16 個

-- open the Lots of Robots tutorial file bounce.max Myobj = $Box001slidertime = 0deletekeys Myobj.pos.controllerMyobj.pos = [0,0,0]deletekeys Myobj[3][2][3].controllerMyobj[3][2][3].value = 0NowTime = 0for i = 1 to 15  do ( --animate on --at time

由程式改寫的對齊資料。還是資料不完善

fn g_filter o = superclassof o == Geometryclassfn find_intersection z_node node_to_z =(  --同樣的條件 數字及計算要比字串快 所以能用數字 不用字串。 oop=case of  (  (gt_yc_Ail.conunt_spn1.value ==1): [0,0,-1]   (gt_yc_Ail.conunt_spn1.value ==2): [0,0,1]

對齊成功。

 fn g_filter o = superclassof o == Geometryclassfn find_intersection z_node node_to_z =(  --同樣的條件 數字及計算要比字串快 所以能用數字 不用字串。 oop=case of  (  (gt_yc_Ail.conunt_spn1.value ==1): [0,0,-1]   (gt_yc_Ail.conunt_spn1.value ==2): [0,0,1]      (gt_yc_Ail.conunt_

自動對齊核心已經完成。這個不錯。

macroScript gt_duiqigognju category:"蓋天工具" ButtonText:"對齊" toolTip:"對齊工具"(  global gt_yc_Ail fn g_filter o = superclassof o == Geometryclass fn find_intersection z_node node_to_z = (   --try(  --同樣的條件 數字及計算要比字串快 所以能用數字 不用字串。  ---改寫成自動的迴圈處理的,

總頁數: 61357 1 .... 9439 9440 9441 9442 9443 .... 61357 Go to: 前往

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.