亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? form1.vb

?? 基于vb.net的autocad二次開發凸輪模型反求與3D動畫模擬根據凸輪掃描位圖反求3d模型模擬凸輪運動顯示凸輪位移曲線。
?? VB
?? 第 1 頁 / 共 2 頁
字號:

Public Class Form1
    Inherits System.Windows.Forms.Form

#Region " Windows 窗體設計器生成的代碼 "

    Public Sub New()
        MyBase.New()

        '該調用是 Windows 窗體設計器所必需的。
        InitializeComponent()

        '在 InitializeComponent() 調用之后添加任何初始化

    End Sub

    '窗體重寫處置以清理組件列表。
    Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
        If disposing Then
            If Not (components Is Nothing) Then
                components.Dispose()
            End If
        End If
        MyBase.Dispose(disposing)
    End Sub

    'Windows 窗體設計器所必需的
    Private components As System.ComponentModel.IContainer

    '注意:以下過程是 Windows 窗體設計器所必需的
    '可以使用 Windows 窗體設計器修改此過程。
    '不要使用代碼編輯器修改它。
    Friend WithEvents PictureBox1 As System.Windows.Forms.PictureBox
    Friend WithEvents Label1 As System.Windows.Forms.Label
    Friend WithEvents Label2 As System.Windows.Forms.Label
    Friend WithEvents Button1 As System.Windows.Forms.Button
    Friend WithEvents TextBox1 As System.Windows.Forms.TextBox
    Friend WithEvents Button2 As System.Windows.Forms.Button
    Friend WithEvents RadioButton1 As System.Windows.Forms.RadioButton
    Friend WithEvents RadioButton2 As System.Windows.Forms.RadioButton
    Friend WithEvents Button3 As System.Windows.Forms.Button
    Friend WithEvents Button4 As System.Windows.Forms.Button
    Friend WithEvents TextBox2 As System.Windows.Forms.TextBox
    Friend WithEvents Label3 As System.Windows.Forms.Label
    Friend WithEvents Label4 As System.Windows.Forms.Label
    Friend WithEvents Button5 As System.Windows.Forms.Button
    Friend WithEvents Button6 As System.Windows.Forms.Button
    Friend WithEvents Label5 As System.Windows.Forms.Label
    Friend WithEvents TextBox3 As System.Windows.Forms.TextBox
    <System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent()
        Me.PictureBox1 = New System.Windows.Forms.PictureBox()
        Me.Label1 = New System.Windows.Forms.Label()
        Me.Label2 = New System.Windows.Forms.Label()
        Me.Button1 = New System.Windows.Forms.Button()
        Me.TextBox1 = New System.Windows.Forms.TextBox()
        Me.Button2 = New System.Windows.Forms.Button()
        Me.RadioButton1 = New System.Windows.Forms.RadioButton()
        Me.RadioButton2 = New System.Windows.Forms.RadioButton()
        Me.Button3 = New System.Windows.Forms.Button()
        Me.Button4 = New System.Windows.Forms.Button()
        Me.TextBox2 = New System.Windows.Forms.TextBox()
        Me.Label3 = New System.Windows.Forms.Label()
        Me.Label4 = New System.Windows.Forms.Label()
        Me.Button5 = New System.Windows.Forms.Button()
        Me.Button6 = New System.Windows.Forms.Button()
        Me.Label5 = New System.Windows.Forms.Label()
        Me.TextBox3 = New System.Windows.Forms.TextBox()
        Me.SuspendLayout()
        '
        'PictureBox1
        '
        Me.PictureBox1.Location = New System.Drawing.Point(8, 8)
        Me.PictureBox1.Name = "PictureBox1"
        Me.PictureBox1.Size = New System.Drawing.Size(272, 224)
        Me.PictureBox1.TabIndex = 1
        Me.PictureBox1.TabStop = False
        '
        'Label1
        '
        Me.Label1.Location = New System.Drawing.Point(352, 24)
        Me.Label1.Name = "Label1"
        Me.Label1.Size = New System.Drawing.Size(64, 16)
        Me.Label1.TabIndex = 6
        Me.Label1.Text = "Label1"
        '
        'Label2
        '
        Me.Label2.Location = New System.Drawing.Point(352, 152)
        Me.Label2.Name = "Label2"
        Me.Label2.Size = New System.Drawing.Size(80, 48)
        Me.Label2.TabIndex = 7
        Me.Label2.Text = "Label2"
        '
        'Button1
        '
        Me.Button1.Location = New System.Drawing.Point(336, 248)
        Me.Button1.Name = "Button1"
        Me.Button1.Size = New System.Drawing.Size(104, 48)
        Me.Button1.TabIndex = 9
        Me.Button1.Text = "Button1"
        '
        'TextBox1
        '
        Me.TextBox1.Location = New System.Drawing.Point(344, 48)
        Me.TextBox1.Name = "TextBox1"
        Me.TextBox1.Size = New System.Drawing.Size(72, 21)
        Me.TextBox1.TabIndex = 10
        Me.TextBox1.Text = "TextBox1"
        '
        'Button2
        '
        Me.Button2.Location = New System.Drawing.Point(336, 312)
        Me.Button2.Name = "Button2"
        Me.Button2.Size = New System.Drawing.Size(104, 48)
        Me.Button2.TabIndex = 11
        Me.Button2.Text = "Button2"
        '
        'RadioButton1
        '
        Me.RadioButton1.Location = New System.Drawing.Point(336, 72)
        Me.RadioButton1.Name = "RadioButton1"
        Me.RadioButton1.Size = New System.Drawing.Size(120, 40)
        Me.RadioButton1.TabIndex = 12
        Me.RadioButton1.Text = "RadioButton1"
        '
        'RadioButton2
        '
        Me.RadioButton2.Location = New System.Drawing.Point(336, 120)
        Me.RadioButton2.Name = "RadioButton2"
        Me.RadioButton2.Size = New System.Drawing.Size(120, 24)
        Me.RadioButton2.TabIndex = 13
        Me.RadioButton2.Text = "RadioButton2"
        '
        'Button3
        '
        Me.Button3.Location = New System.Drawing.Point(72, 280)
        Me.Button3.Name = "Button3"
        Me.Button3.Size = New System.Drawing.Size(88, 32)
        Me.Button3.TabIndex = 14
        Me.Button3.Text = "Button3"
        '
        'Button4
        '
        Me.Button4.Location = New System.Drawing.Point(184, 280)
        Me.Button4.Name = "Button4"
        Me.Button4.Size = New System.Drawing.Size(80, 32)
        Me.Button4.TabIndex = 15
        Me.Button4.Text = "Button4"
        '
        'TextBox2
        '
        Me.TextBox2.Location = New System.Drawing.Point(72, 248)
        Me.TextBox2.Name = "TextBox2"
        Me.TextBox2.Size = New System.Drawing.Size(56, 21)
        Me.TextBox2.TabIndex = 16
        Me.TextBox2.Text = "TextBox2"
        '
        'Label3
        '
        Me.Label3.Location = New System.Drawing.Point(352, 200)
        Me.Label3.Name = "Label3"
        Me.Label3.Size = New System.Drawing.Size(80, 40)
        Me.Label3.TabIndex = 8
        Me.Label3.Text = "Label3"
        '
        'Label4
        '
        Me.Label4.Location = New System.Drawing.Point(16, 248)
        Me.Label4.Name = "Label4"
        Me.Label4.Size = New System.Drawing.Size(48, 16)
        Me.Label4.TabIndex = 17
        Me.Label4.Text = "Label4"
        '
        'Button5
        '
        Me.Button5.Location = New System.Drawing.Point(72, 328)
        Me.Button5.Name = "Button5"
        Me.Button5.Size = New System.Drawing.Size(88, 32)
        Me.Button5.TabIndex = 18
        Me.Button5.Text = "Button5"
        '
        'Button6
        '
        Me.Button6.Location = New System.Drawing.Point(184, 328)
        Me.Button6.Name = "Button6"
        Me.Button6.Size = New System.Drawing.Size(88, 32)
        Me.Button6.TabIndex = 19
        Me.Button6.Text = "Button6"
        '
        'Label5
        '
        Me.Label5.Location = New System.Drawing.Point(144, 248)
        Me.Label5.Name = "Label5"
        Me.Label5.Size = New System.Drawing.Size(80, 16)
        Me.Label5.TabIndex = 21
        Me.Label5.Text = "Label5"
        '
        'TextBox3
        '
        Me.TextBox3.Location = New System.Drawing.Point(224, 248)
        Me.TextBox3.Name = "TextBox3"
        Me.TextBox3.Size = New System.Drawing.Size(56, 21)
        Me.TextBox3.TabIndex = 20
        Me.TextBox3.Text = "TextBox3"
        '
        'Form1
        '
        Me.AutoScaleBaseSize = New System.Drawing.Size(6, 14)
        Me.ClientSize = New System.Drawing.Size(480, 397)
        Me.Controls.AddRange(New System.Windows.Forms.Control() {Me.Label5, Me.TextBox3, Me.Button6, Me.Button5, Me.Label4, Me.TextBox2, Me.Button4, Me.Button3, Me.RadioButton2, Me.RadioButton1, Me.Button2, Me.TextBox1, Me.Button1, Me.Label3, Me.Label2, Me.Label1, Me.PictureBox1})
        Me.Name = "Form1"
        Me.Text = "Form1"
        Me.ResumeLayout(False)

    End Sub

#End Region

    Dim Acadapp As AutoCAD.AcadApplication
    Dim XMouseDown, YMouseDown '獲得鼠標在圖片上單擊點的X、Y 坐標
    Dim MouseDownpointsColor As Color '獲得鼠標在圖片上單擊點的顏色
    Dim Xp(), Yp() As Integer '動態數組,存放圖形內或外輪廓各點坐標
    Dim Mpoints As Integer  '存放圖形內或外輪廓各點坐標點總數
    Dim solidObj() As AutoCAD.Acad3DSolid '三維造型實體結果。
    Dim Numcurves As Integer '平面圖形內、外輪廓曲線總數
    Dim splineObj() As AutoCAD.AcadEntity '第Numcurves條輪廓曲線
    Dim OutlineDone As Boolean '布爾值,判斷是否已經先單擊外輪廓
    Dim I As Integer '臨時變量

    '創建一個新的位圖對象實例
    Dim myBitmap As New Bitmap(Application.StartupPath + "\凸輪.bmp")


    Dim solidObjT As AutoCAD.Acad3DSolid '凸輪實體
    Dim gCenterY(360) As Double '滾子中心y坐標
    Dim TCenter(2) As Double '凸輪轉動中心
    Dim jg As Integer '凸輪轉動間隔角度
    Dim Xzhou, Yzhou As AutoCAD.Acad3DSolid  '繪制顯示滾子位移曲線的坐標軸




    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

        Me.Text = "實例16凸輪模型反求與3D動畫模擬"

        Me.Label1.Text = "精度:"
        Me.Label2.Text = "第1步:單擊外輪廓區域"
        Me.Label3.Text = "第2步:單擊內輪廓區域"
        Me.Label4.Text = "偏置距e"
        Me.Label5.Text = "轉動間隔角度"

        Me.TextBox1.Text = 15
        Me.TextBox2.Text = 20
        Me.TextBox3.Text = 10

        Me.RadioButton1.Text = "非均勻有理B樣條曲線擬合"
        Me.RadioButton2.Text = "多義線擬合"
        Me.RadioButton1.Checked = True


        Me.Button1.Text = "第3步:三維模型反求顯示"
        Me.Button2.Text = "圖形增強處理(可選)"
        Me.Button3.Text = "加載滾子圖形"
        Me.Button4.Text = "生成數據"
        Me.Button5.Text = "3D動畫"
        Me.Button6.Text = "結束"

        '裝載圖片
        Me.PictureBox1.SizeMode = PictureBoxSizeMode.AutoSize
        Me.PictureBox1.Image = myBitmap

        OutlineDone = False

        Call 連接AutoCAD()


    End Sub

    Private Sub PictureBox1_MouseDown(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles PictureBox1.MouseDown

        '獲得鼠標在圖片上單擊點的X、Y 坐標
        XMouseDown = e.X
        YMouseDown = e.Y

        '獲得鼠標在圖片上單擊點的顏色
        MouseDownpointsColor = myBitmap.GetPixel(e.X, e.Y)

        On Error GoTo ErrorAttention
        If OutlineDone = False Then
            Call 求外輪廓點坐標()
            If Mpoints <= 1 Then
                MsgBox("請單擊另一點")
                Exit Sub
            End If
        Else
            Call 求內輪廓點坐標()
            If Mpoints <= 1 Then
                MsgBox("請單擊另一點")
                Exit Sub
            End If

            '求凸輪轉動中心坐標
            Static T As Boolean
            Dim Xmin, Ymin, Xmax, Ymax
            Xmin = 10 ^ 5
            Xmax = 0
            If T = False Then
                For I = 0 To Mpoints

                    If Xmin > Xp(I) Then
                        Xmin = Xp(I)
                        Ymin = Yp(I)
                    End If

                    If Xmax < Xp(I) Then
                        Xmax = Xp(I)
                        Ymax = Yp(I)
                    End If

                Next

                TCenter(0) = (Xmax + Xmin) / 2
                TCenter(1) = -(Ymax + Ymin) / 2
                TCenter(2) = 0
                T = True
            End If

        End If
        Call 造型()
        Exit Sub
ErrorAttention:
        Err.Clear()
        MsgBox("必須先單擊外輪廓")
    End Sub

    Sub 求外輪廓點坐標()
        Dim FistX, FistY '第一點
        Dim myPen As New Pen(Color.Red)

        Mpoints = -1
        For I = YMouseDown To 0 Step -1
            If myBitmap.GetPixel(XMouseDown, I).ToArgb <> MouseDownpointsColor.ToArgb Then
                Mpoints = Mpoints + 1
                ReDim Preserve Xp(Mpoints), Yp(Mpoints)
                FistX = XMouseDown
                FistY = I + 1
                Xp(Mpoints) = XMouseDown
                Yp(Mpoints) = I + 1

                '用紅色描已經辨別出來的外輪廓
                Me.PictureBox1.CreateGraphics.DrawEllipse(myPen, Xp(Mpoints), Yp(Mpoints), 1, 1)
                Exit For
            End If
        Next I

        Do
            Call 搜尋輪廓邊沿坐標()

            '當搜尋到與第一點坐標相同點時停止搜尋
        Loop Until FistX = Xp(Mpoints) And (FistY = Yp(Mpoints) Or FistY = Yp(Mpoints) + 1 Or FistY = Yp(Mpoints) - 1)

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
狠狠狠色丁香婷婷综合久久五月| 国产欧美一区二区精品性色超碰 | 成人自拍视频在线观看| 美女视频黄久久| 日本伊人午夜精品| 美女在线视频一区| 极品少妇xxxx精品少妇偷拍| 天天操天天色综合| 乱一区二区av| 成人综合激情网| 色综合一区二区| 色噜噜久久综合| 欧美精品在欧美一区二区少妇| 欧美日韩不卡一区| 精品美女一区二区| 国产精品国产三级国产aⅴ原创| 自拍偷在线精品自拍偷无码专区| 亚洲欧美另类在线| 视频一区国产视频| 精品午夜久久福利影院 | 国产剧情av麻豆香蕉精品| 国内外成人在线| 成人午夜激情在线| 欧美三级韩国三级日本一级| 日韩一区二区三区免费看 | 日韩欧美亚洲国产另类| 久久这里只有精品首页| 1000精品久久久久久久久| 亚洲高清在线视频| 国产一区二区三区| 欧美日韩国产综合一区二区| 久久亚洲综合av| 亚洲免费观看高清完整版在线| 日韩 欧美一区二区三区| 懂色中文一区二区在线播放| 欧美日韩激情一区二区三区| 国产日韩精品一区| 视频一区二区不卡| 波多野结衣中文一区| 91精品国产一区二区三区| 国产精品国产三级国产有无不卡| 偷窥少妇高潮呻吟av久久免费| 国产不卡免费视频| 欧美一级免费观看| 亚洲美女偷拍久久| 国产成人欧美日韩在线电影| 666欧美在线视频| 亚洲毛片av在线| 国产精品自拍三区| 欧美精品丝袜中出| 亚洲精品免费看| 国产 欧美在线| 精品久久久久久久一区二区蜜臀| 一区二区三区国产精品| 成人黄色a**站在线观看| 日韩精品一区二区三区三区免费| 一区二区三区四区亚洲| 北岛玲一区二区三区四区| 久久夜色精品国产欧美乱极品| 日韩国产在线一| 欧美中文字幕久久| 亚洲黄色小视频| 波多野结衣中文一区| 国产精品欧美久久久久一区二区| 国内精品自线一区二区三区视频| 日韩一区二区三区在线| 蜜臀国产一区二区三区在线播放| 欧美人妇做爰xxxⅹ性高电影| 亚洲一二三区在线观看| 91精品1区2区| 亚洲午夜在线电影| 成人av资源在线观看| 国产盗摄精品一区二区三区在线 | 日本丶国产丶欧美色综合| 欧美va亚洲va国产综合| 日本不卡视频一二三区| 欧美伦理影视网| 日韩av网站免费在线| 日韩午夜精品电影| 激情国产一区二区| 国产欧美一区视频| 成人性生交大片免费看视频在线 | 欧美丰满嫩嫩电影| 日本成人在线不卡视频| 精品日韩一区二区三区免费视频| 久久国产精品一区二区| 久久嫩草精品久久久精品| 国产精品一区二区黑丝| 国产精品久久久久一区二区三区共 | 蜜臀av亚洲一区中文字幕| 欧美日韩高清在线播放| 亚洲大型综合色站| 91精品国产手机| 国产资源在线一区| 日本一区二区三区电影| 国产成人福利片| 日韩伦理av电影| 欧美日韩国产免费一区二区| 欧美a级理论片| 久久精品视频一区二区| 成人av综合在线| 亚洲毛片av在线| 日韩欧美国产精品| 99久久精品国产观看| 亚洲国产另类精品专区| 久久奇米777| 色综合久久六月婷婷中文字幕| 夜夜揉揉日日人人青青一国产精品| 欧美在线一区二区三区| 激情小说欧美图片| 亚洲免费在线播放| 日韩欧美一区二区久久婷婷| 蜜臀国产一区二区三区在线播放| 中文字幕在线一区二区三区| 欧美日韩国产免费一区二区 | 中文字幕日韩一区| 91精品黄色片免费大全| 成人黄色软件下载| 免费观看成人鲁鲁鲁鲁鲁视频| 国产亚洲一区二区三区| 7777精品伊人久久久大香线蕉的 | 在线免费av一区| 国产精一区二区三区| 亚洲国产乱码最新视频| 国产精品理伦片| www日韩大片| 欧美精品视频www在线观看| 91丨porny丨蝌蚪视频| 国产一区二区精品在线观看| 日韩精品每日更新| 一区二区三区电影在线播| 亚洲国产精品ⅴa在线观看| 精品国产乱码久久久久久久久| 欧美三级蜜桃2在线观看| 91丨porny丨在线| 成人免费视频一区二区| 国产一区二区三区视频在线播放| 日韩在线观看一区二区| 亚洲地区一二三色| 亚洲自拍欧美精品| 亚洲美女少妇撒尿| 一区二区中文视频| 国产精品伦理在线| 中文字幕在线播放不卡一区| 久久夜色精品国产欧美乱极品| 欧美mv日韩mv国产网站app| 91精品国产欧美一区二区18| 欧美久久一二区| 欧美日本视频在线| 666欧美在线视频| 日韩精品一区二区三区四区视频| 欧美一级高清大全免费观看| 91麻豆精品91久久久久久清纯| 欧美夫妻性生活| 日韩欧美国产三级电影视频| 精品动漫一区二区三区在线观看| 日韩欧美一二区| 国产亚洲欧美一区在线观看| 国产亚洲人成网站| 国产精品国产三级国产| 一区二区三区四区亚洲| 亚洲不卡av一区二区三区| 天天操天天色综合| 激情国产一区二区| 成人在线视频一区| 日本精品一级二级| 欧美乱妇23p| 亚洲精品一线二线三线无人区| 欧美激情在线看| 亚洲伦理在线精品| 日本强好片久久久久久aaa| 日本成人在线看| 成人毛片在线观看| 欧美日韩精品一区二区天天拍小说 | 国产日韩欧美一区二区三区综合| 国产欧美一区二区精品婷婷| 亚洲色图欧美偷拍| 水蜜桃久久夜色精品一区的特点| 麻豆久久一区二区| av亚洲精华国产精华精华| 91成人国产精品| 精品三级在线观看| 亚洲男人电影天堂| 麻豆国产91在线播放| caoporen国产精品视频| 欧美日韩亚洲不卡| 国产日韩欧美精品电影三级在线| 一区二区不卡在线播放| 激情综合网激情| 在线观看亚洲a| 中文字幕欧美日韩一区| 日韩不卡一二三区| eeuss鲁一区二区三区| 日韩视频在线观看一区二区| 成人欧美一区二区三区视频网页| 免费成人av在线| 欧洲人成人精品| 国产精品久久久久四虎| 首页国产丝袜综合| 91麻豆精东视频|