home *** CD-ROM | disk | FTP | other *** search
/ Planet Source Code Jumbo …e CD Visual Basic 1 to 7 / 6_2008-2009.ISO / data / zips / Image_Effe21315210222008.psc / Form1.frm < prev    next >
Text File  |  2008-10-20  |  16KB  |  567 lines

  1. VERSION 5.00
  2. Begin VB.Form frmMain 
  3.    BorderStyle     =   1  'Fixed Single
  4.    Caption         =   "Skyler Lyon's Imaging Effects 2.0"
  5.    ClientHeight    =   7935
  6.    ClientLeft      =   45
  7.    ClientTop       =   435
  8.    ClientWidth     =   15120
  9.    LinkTopic       =   "Form1"
  10.    MaxButton       =   0   'False
  11.    MinButton       =   0   'False
  12.    ScaleHeight     =   7935
  13.    ScaleWidth      =   15120
  14.    StartUpPosition =   2  'CenterScreen
  15.    Begin VB.PictureBox picTemp 
  16.       AutoRedraw      =   -1  'True
  17.       BackColor       =   &H00FFFFFF&
  18.       BorderStyle     =   0  'None
  19.       Height          =   7215
  20.       Left            =   840
  21.       ScaleHeight     =   7215
  22.       ScaleWidth      =   5535
  23.       TabIndex        =   39
  24.       Top             =   8200
  25.       Width           =   5535
  26.    End
  27.    Begin VB.CommandButton cmdPointalism 
  28.       Caption         =   "Pointalism"
  29.       Height          =   375
  30.       Left            =   8160
  31.       TabIndex        =   38
  32.       Top             =   2520
  33.       Width           =   1215
  34.    End
  35.    Begin VB.CommandButton cmdPixilated 
  36.       Caption         =   "Pixilated"
  37.       Height          =   375
  38.       Left            =   6960
  39.       TabIndex        =   37
  40.       Top             =   2520
  41.       Width           =   1215
  42.    End
  43.    Begin VB.CommandButton cmdEmboss 
  44.       Caption         =   "Emboss"
  45.       Height          =   375
  46.       Left            =   5760
  47.       TabIndex        =   36
  48.       Top             =   2520
  49.       Width           =   1215
  50.    End
  51.    Begin VB.CommandButton cmdSilhuette 
  52.       Caption         =   "Silhuette"
  53.       Height          =   375
  54.       Left            =   8160
  55.       TabIndex        =   35
  56.       Top             =   2160
  57.       Width           =   1215
  58.    End
  59.    Begin VB.CommandButton cmdFlatten2 
  60.       Caption         =   "Flatten2"
  61.       Height          =   375
  62.       Left            =   6960
  63.       TabIndex        =   34
  64.       Top             =   2160
  65.       Width           =   1215
  66.    End
  67.    Begin VB.CommandButton cmdIncoherence 
  68.       Caption         =   "Incoherence"
  69.       Height          =   375
  70.       Left            =   5760
  71.       TabIndex        =   33
  72.       Top             =   1560
  73.       Width           =   1215
  74.    End
  75.    Begin VB.CommandButton cmdVividNeg 
  76.       Caption         =   "Vivid Negation"
  77.       Height          =   375
  78.       Left            =   8160
  79.       TabIndex        =   32
  80.       Top             =   3480
  81.       Width           =   1215
  82.    End
  83.    Begin VB.CommandButton cmdNegative 
  84.       Caption         =   "Negative"
  85.       Height          =   375
  86.       Left            =   6960
  87.       TabIndex        =   31
  88.       Top             =   3480
  89.       Width           =   1215
  90.    End
  91.    Begin VB.CommandButton cmdNeonNegation 
  92.       Caption         =   "Neon Negation"
  93.       Height          =   375
  94.       Left            =   5760
  95.       TabIndex        =   30
  96.       Top             =   3840
  97.       Width           =   1215
  98.    End
  99.    Begin VB.CommandButton cmdWarped 
  100.       Caption         =   "Warped"
  101.       Height          =   375
  102.       Left            =   8160
  103.       TabIndex        =   29
  104.       Top             =   1200
  105.       Width           =   1215
  106.    End
  107.    Begin VB.CommandButton cmdSetMain 
  108.       Caption         =   "Set To Main Image"
  109.       Height          =   375
  110.       Left            =   9480
  111.       TabIndex        =   26
  112.       Top             =   7440
  113.       Width           =   1815
  114.    End
  115.    Begin VB.CommandButton cmdSave 
  116.       Caption         =   "Save Image"
  117.       Height          =   375
  118.       Left            =   13920
  119.       TabIndex        =   25
  120.       Top             =   7440
  121.       Width           =   1095
  122.    End
  123.    Begin VB.CommandButton cmdLoadImage 
  124.       Caption         =   "Load Image"
  125.       Height          =   375
  126.       Left            =   120
  127.       TabIndex        =   24
  128.       Top             =   7440
  129.       Width           =   1095
  130.    End
  131.    Begin VB.PictureBox imgNo 
  132.       Appearance      =   0  'Flat
  133.       AutoRedraw      =   -1  'True
  134.       BackColor       =   &H80000005&
  135.       ForeColor       =   &H80000008&
  136.       Height          =   135
  137.       Left            =   6000
  138.       ScaleHeight     =   105
  139.       ScaleWidth      =   105
  140.       TabIndex        =   23
  141.       Top             =   8040
  142.       Width           =   135
  143.    End
  144.    Begin VB.CommandButton cmdSilk 
  145.       Caption         =   "Silk"
  146.       Height          =   375
  147.       Left            =   8160
  148.       TabIndex        =   22
  149.       Top             =   3120
  150.       Width           =   1215
  151.    End
  152.    Begin VB.CommandButton cmdFlatten 
  153.       Caption         =   "Flatten"
  154.       Height          =   375
  155.       Left            =   5760
  156.       TabIndex        =   21
  157.       Top             =   2160
  158.       Width           =   1215
  159.    End
  160.    Begin VB.CommandButton cmdVividSilk 
  161.       Caption         =   "VividSilk"
  162.       Height          =   375
  163.       Left            =   5760
  164.       TabIndex        =   20
  165.       Top             =   3480
  166.       Width           =   1215
  167.    End
  168.    Begin VB.CommandButton cmdSunShinnyDay 
  169.       Caption         =   "SunShinnyDay"
  170.       Height          =   375
  171.       Left            =   6960
  172.       TabIndex        =   19
  173.       Top             =   3120
  174.       Width           =   1215
  175.    End
  176.    Begin VB.CommandButton cmdGlowInTheDark 
  177.       Caption         =   "GlowInDark"
  178.       Height          =   375
  179.       Left            =   5760
  180.       TabIndex        =   18
  181.       Top             =   3120
  182.       Width           =   1215
  183.    End
  184.    Begin VB.CommandButton cmdDecreaseRGB 
  185.       Caption         =   "DecreaseRGB"
  186.       Height          =   375
  187.       Left            =   6960
  188.       TabIndex        =   17
  189.       Top             =   1200
  190.       Width           =   1215
  191.    End
  192.    Begin VB.CommandButton cmdDecreaseBlue 
  193.       Caption         =   "DecreaseBlue"
  194.       Height          =   375
  195.       Left            =   5760
  196.       TabIndex        =   16
  197.       Top             =   1200
  198.       Width           =   1215
  199.    End
  200.    Begin VB.CommandButton cmdDecreaseGreen 
  201.       Caption         =   "DecreaseG"
  202.       Height          =   375
  203.       Left            =   8160
  204.       TabIndex        =   15
  205.       Top             =   840
  206.       Width           =   1215
  207.    End
  208.    Begin VB.CommandButton cmdDecreaseRed 
  209.       Caption         =   "DecreaseRed"
  210.       Height          =   375
  211.       Left            =   6960
  212.       TabIndex        =   14
  213.       Top             =   840
  214.       Width           =   1215
  215.    End
  216.    Begin VB.CommandButton cmdIncreaseRGB 
  217.       Caption         =   "IncreaseRGB"
  218.       Height          =   375
  219.       Left            =   5760
  220.       TabIndex        =   13
  221.       Top             =   840
  222.       Width           =   1215
  223.    End
  224.    Begin VB.CommandButton cmdIncreaseBlue 
  225.       Caption         =   "IncreaseBlue"
  226.       Height          =   375
  227.       Left            =   8160
  228.       TabIndex        =   12
  229.       Top             =   480
  230.       Width           =   1215
  231.    End
  232.    Begin VB.CommandButton cmdIncreaseGreen 
  233.       Caption         =   "IncreaseGreen"
  234.       Height          =   375
  235.       Left            =   6960
  236.       TabIndex        =   11
  237.       Top             =   480
  238.       Width           =   1215
  239.    End
  240.    Begin VB.CommandButton cmdIncreaseRed 
  241.       Caption         =   "IncreaseRed"
  242.       Height          =   375
  243.       Left            =   5760
  244.       TabIndex        =   10
  245.       Top             =   480
  246.       Width           =   1215
  247.    End
  248.    Begin VB.CommandButton cmdNoGreen 
  249.       Caption         =   "NoGreen"
  250.       Height          =   375
  251.       Left            =   8160
  252.       TabIndex        =   9
  253.       Top             =   120
  254.       Width           =   1215
  255.    End
  256.    Begin VB.CommandButton cmdNoBlue 
  257.       Caption         =   "NoBlue"
  258.       Height          =   375
  259.       Left            =   6960
  260.       TabIndex        =   8
  261.       Top             =   120
  262.       Width           =   1215
  263.    End
  264.    Begin VB.CommandButton cmdNoRed 
  265.       Caption         =   "NoRed"
  266.       Height          =   375
  267.       Left            =   5760
  268.       TabIndex        =   7
  269.       Top             =   120
  270.       Width           =   1215
  271.    End
  272.    Begin VB.CommandButton cmdBlur2 
  273.       Caption         =   "Blur More"
  274.       Height          =   375
  275.       Left            =   6960
  276.       TabIndex        =   6
  277.       Top             =   4800
  278.       Width           =   1215
  279.    End
  280.    Begin VB.CommandButton cmdBlur1 
  281.       Caption         =   "Blur"
  282.       Height          =   375
  283.       Left            =   5760
  284.       TabIndex        =   5
  285.       Top             =   4800
  286.       Width           =   1215
  287.    End
  288.    Begin VB.CommandButton cmdDarken 
  289.       Caption         =   "Darken"
  290.       Height          =   375
  291.       Left            =   8160
  292.       TabIndex        =   4
  293.       Top             =   4440
  294.       Width           =   1215
  295.    End
  296.    Begin VB.CommandButton cmdLighten 
  297.       Caption         =   "Lighten"
  298.       Height          =   375
  299.       Left            =   6960
  300.       TabIndex        =   3
  301.       Top             =   4440
  302.       Width           =   1215
  303.    End
  304.    Begin VB.CommandButton cmdGreyScale 
  305.       Caption         =   "GrayScale"
  306.       Height          =   375
  307.       Left            =   5760
  308.       TabIndex        =   2
  309.       Top             =   4440
  310.       Width           =   1215
  311.    End
  312.    Begin VB.PictureBox Picture2 
  313.       Appearance      =   0  'Flat
  314.       AutoRedraw      =   -1  'True
  315.       BackColor       =   &H80000005&
  316.       ForeColor       =   &H80000008&
  317.       Height          =   7215
  318.       Left            =   9480
  319.       ScaleHeight     =   7185
  320.       ScaleWidth      =   5505
  321.       TabIndex        =   1
  322.       Top             =   120
  323.       Width           =   5535
  324.    End
  325.    Begin VB.PictureBox Picture1 
  326.       Appearance      =   0  'Flat
  327.       AutoRedraw      =   -1  'True
  328.       BackColor       =   &H80000005&
  329.       ForeColor       =   &H80000008&
  330.       Height          =   7215
  331.       Left            =   120
  332.       Picture         =   "Form1.frx":0000
  333.       ScaleHeight     =   7185
  334.       ScaleWidth      =   5505
  335.       TabIndex        =   0
  336.       Top             =   120
  337.       Width           =   5535
  338.    End
  339.    Begin VB.Label lblTime 
  340.       Height          =   255
  341.       Left            =   6600
  342.       TabIndex        =   28
  343.       Top             =   7440
  344.       Width           =   2775
  345.    End
  346.    Begin VB.Label lblT 
  347.       Caption         =   "Time (MS):"
  348.       Height          =   255
  349.       Left            =   5760
  350.       TabIndex        =   27
  351.       Top             =   7440
  352.       Width           =   855
  353.    End
  354. End
  355. Attribute VB_Name = "frmMain"
  356. Attribute VB_GlobalNameSpace = False
  357. Attribute VB_Creatable = False
  358. Attribute VB_PredeclaredId = True
  359. Attribute VB_Exposed = False
  360. 'Title:           frmMain
  361. 'Version:         2.0
  362. 'Date:            10/07/2008
  363. 'Author:          Skyler Lyon
  364. 'Copyright:       ⌐ 2008 Skyler Lyon
  365. 'Description:     Main window.
  366.  
  367. Option Explicit
  368.  
  369. Private Sub cmdBlur1_Click()
  370. lblTime.Caption = Blur(Picture1, picTemp)
  371. Picture2.Picture = picTemp.Image
  372. End Sub
  373.  
  374. Private Sub cmdBlur2_Click()
  375. lblTime.Caption = BlurMore(Picture1, picTemp)
  376. Picture2.Picture = picTemp.Image
  377. End Sub
  378.  
  379. Private Sub cmdDarken_Click()
  380. lblTime.Caption = Darken(Picture1, picTemp, 50)
  381. Picture2.Picture = picTemp.Image
  382. End Sub
  383.  
  384. Private Sub cmdDecreaseBlue_Click()
  385. lblTime.Caption = IncreaseBlue(Picture1, picTemp, -50)
  386. Picture2.Picture = picTemp.Image
  387. End Sub
  388.  
  389. Private Sub cmdDecreaseGreen_Click()
  390. lblTime.Caption = IncreaseGreen(Picture1, picTemp, -50)
  391. Picture2.Picture = picTemp.Image
  392. End Sub
  393.  
  394. Private Sub cmdDecreaseRed_Click()
  395. lblTime.Caption = IncreaseRed(Picture1, picTemp, -50)
  396. Picture2.Picture = picTemp.Image
  397. End Sub
  398.  
  399. Private Sub cmdDecreaseRGB_Click()
  400. lblTime.Caption = IncreaseRGB(Picture1, picTemp, -50, -100, -50)
  401. Picture2.Picture = picTemp.Image
  402. End Sub
  403.  
  404. Private Sub cmdEmboss_Click()
  405. lblTime.Caption = Emboss(Picture1, picTemp, 100)
  406. Picture2.Picture = picTemp.Image
  407. End Sub
  408.  
  409. Private Sub cmdFlatten_Click()
  410. lblTime.Caption = Flatten(Picture1, picTemp)
  411. Picture2.Picture = picTemp.Image
  412. End Sub
  413.  
  414. Private Sub cmdFlatten2_Click()
  415. lblTime.Caption = Flatten2(Picture1, picTemp)
  416. Picture2.Picture = picTemp.Image
  417. End Sub
  418.  
  419. Private Sub cmdGlowInTheDark_Click()
  420. lblTime.Caption = GlowInTheDark(Picture1, picTemp, 1)
  421. Picture2.Picture = picTemp.Image
  422. End Sub
  423.  
  424. Private Sub cmdGreyScale_Click()
  425. lblTime.Caption = GrayScale(Picture1, picTemp)
  426. Picture2.Picture = picTemp.Image
  427. End Sub
  428.  
  429. Private Sub cmdIncoherence_Click()
  430. lblTime.Caption = Incoherence(Picture1, picTemp)
  431. Picture2.Picture = picTemp.Image
  432. End Sub
  433.  
  434. Private Sub cmdIncreaseBlue_Click()
  435. lblTime.Caption = IncreaseBlue(Picture1, picTemp, 50)
  436. Picture2.Picture = picTemp.Image
  437. End Sub
  438.  
  439. Private Sub cmdIncreaseGreen_Click()
  440. lblTime.Caption = IncreaseGreen(Picture1, picTemp, 50)
  441. Picture2.Picture = picTemp.Image
  442. End Sub
  443.  
  444. Private Sub cmdIncreaseRed_Click()
  445. lblTime.Caption = IncreaseRed(Picture1, picTemp, 50)
  446. Picture2.Picture = picTemp.Image
  447. End Sub
  448.  
  449. Private Sub cmdIncreaseRGB_Click()
  450. lblTime.Caption = IncreaseRGB(Picture1, picTemp, 50, 100, 50)
  451. Picture2.Picture = picTemp.Image
  452. End Sub
  453.  
  454. Private Sub cmdLighten_Click()
  455. lblTime.Caption = Lighten(Picture1, picTemp, 50)
  456. Picture2.Picture = picTemp.Image
  457. End Sub
  458.  
  459. Private Sub cmdLoadImage_Click()
  460. Dim FileName As String
  461.  
  462. FileName = fncGetFileNametoOpen("Open Image File", "All Files|*.*", "")
  463. If IsValidFile(FileName) = False Then
  464.     Exit Sub
  465. End If
  466.  
  467. On Error GoTo No_Open
  468.  
  469. Open FileName For Input As #1
  470. Picture1.Picture = LoadPicture(FileName)
  471. Close 1
  472. Exit Sub
  473. No_Open:
  474. Resume ExitLine
  475. ExitLine:
  476. Exit Sub
  477. End Sub
  478.  
  479. Private Sub cmdNegative_Click()
  480. lblTime.Caption = Negative(Picture1, picTemp)
  481. Picture2.Picture = picTemp.Image
  482. End Sub
  483.  
  484. Private Sub cmdNeonNegation_Click()
  485. lblTime.Caption = NeonNegation(Picture1, picTemp, 255)
  486. Picture2.Picture = picTemp.Image
  487. End Sub
  488.  
  489. Private Sub cmdNoBlue_Click()
  490. lblTime.Caption = NoBlue(Picture1, picTemp)
  491. Picture2.Picture = picTemp.Image
  492. End Sub
  493.  
  494. Private Sub cmdNoGreen_Click()
  495. lblTime.Caption = NoGreen(Picture1, picTemp)
  496. Picture2.Picture = picTemp.Image
  497. End Sub
  498.  
  499. Private Sub cmdNoRed_Click()
  500. lblTime.Caption = NoRed(Picture1, picTemp)
  501. Picture2.Picture = picTemp.Image
  502. End Sub
  503.  
  504. Private Sub cmdPixilated_Click()
  505. lblTime.Caption = Pixilated(Picture1, picTemp)
  506. Picture2.Picture = picTemp.Image
  507. End Sub
  508.  
  509. Private Sub cmdPointalism_Click()
  510. lblTime.Caption = Pointalism(Picture1, picTemp, 2)
  511. Picture2.Picture = picTemp.Image
  512. End Sub
  513.  
  514. Private Sub cmdSave_Click()
  515. Dim FileName As String
  516.  
  517. FileName = fncGetFileNametoSave("Bitmap Files|*.bmp", "", "Save Bitmap Image File")
  518. If IsValidFile(FileName) = False Then
  519.     Exit Sub
  520. End If
  521.  
  522. On Error GoTo No_Save
  523.  
  524. Open FileName For Output As #2
  525. SavePicture Picture2.Picture, FileName
  526. Close 2
  527. Exit Sub
  528. No_Save:
  529. Resume ExitLine
  530. ExitLine:
  531. Exit Sub
  532. End Sub
  533.  
  534. Private Sub cmdSetMain_Click()
  535. Set Picture1.Picture = Picture2.Picture
  536. End Sub
  537.  
  538. Private Sub cmdSilhuette_Click()
  539. lblTime.Caption = Silhuette(Picture1, picTemp)
  540. Picture2.Picture = picTemp.Image
  541. End Sub
  542.  
  543. Private Sub cmdSilk_Click()
  544. lblTime.Caption = Silk(Picture1, picTemp)
  545. Picture2.Picture = picTemp.Image
  546. End Sub
  547.  
  548. Private Sub cmdSunShinnyDay_Click()
  549. lblTime.Caption = GlowInTheDark(Picture1, picTemp, 10)
  550. Picture2.Picture = picTemp.Image
  551. End Sub
  552.  
  553. Private Sub cmdVividNeg_Click()
  554. lblTime.Caption = VividNegation(Picture1, picTemp)
  555. Picture2.Picture = picTemp.Image
  556. End Sub
  557.  
  558. Private Sub cmdVividSilk_Click()
  559. lblTime.Caption = VividSilk(Picture1, picTemp)
  560. Picture2.Picture = picTemp.Image
  561. End Sub
  562.  
  563. Private Sub cmdWarped_Click()
  564. lblTime.Caption = Warped(Picture1, picTemp)
  565. Picture2.Picture = picTemp.Image
  566. End Sub
  567.