thnx but er.. my visual basic couldn't upgrade the file to visual basic.net2003 is there by anychance u could just type cut/paste the code realy quick?
Private Declare Function PlgBlt Lib "gdi32" (ByVal hdcDest As Long, lpPoint As POINTAPI, ByVal hdcSrc As Long, ByVal nXSrc As Long, ByVal nYSrc As Long, ByVal nWidth As Long, ByVal nHeight As Long, ByVal hbmMask As Long, ByVal xMask As Long, ByVal yMask As Long) As Long
Private Sub Slider1_Click()
Angle = Slider1 / 100
Rotate Picture2, Picture1, Angle
End Sub
Private Sub Slider1_Scroll()
Angle = Slider1 / 100
Rotate Picture2, Picture1, Angle
End Sub
Private Sub Rotate(picDest As PictureBox, picsrc As PictureBox, Angle As Double)
err....i'm in high shool doing my second semeseter of visual basic.....i don't understand half the code. is there a simple property value u can change to rotate the image?
Private Declare Function PlgBlt Lib "gdi32" (ByVal hdcDest As Long, lpPoint As POINTAPI, ByVal hdcSrc As Long, ByVal nXSrc As Long, ByVal nYSrc As Long, ByVal nWidth As Long, ByVal nHeight As Long, ByVal hbmMask As Long, ByVal xMask As Long, ByVal yMask As Long) As Long
Private Sub Slider1_Click()
Angle = Slider1 / 100
Rotate Picture1, Picture2, Angle 'Change this line
End Sub
Private Sub Slider1_Scroll()
Angle = Slider1 / 100
Rotate Picture1, Picture2, Angle 'Change this line
End Sub
Private Sub Rotate(picDest As PictureBox, picsrc As PictureBox, Angle As Double)
Assuming from your "visual basic.net 2003" thing I think you should be posting in the VB.net section, not here. seriously it's right below this one. You can't miss it. You shouldn't have missed it.
Remember, if someone's post was not helpful, you can always rate their post negatively .
Private Declare Function PlgBlt Lib "gdi32" (ByVal hdcDest As Long, lpPoint As POINTAPI, ByVal hdcSrc As Long, ByVal nXSrc As Long, ByVal nYSrc As Long, ByVal nWidth As Long, ByVal nHeight As Long, ByVal hbmMask As Long, ByVal xMask As Long, ByVal yMask As Long) As Long
Private Sub Slider1_Click()
Angle = Slider1 / 100
Rotate Picture1, Picture2, Angle 'Change this line
End Sub
Private Sub Slider1_Scroll()
Angle = Slider1 / 100
Rotate Picture1, Picture2, Angle 'Change this line
End Sub
Private Sub Rotate(picDest As PictureBox, picsrc As PictureBox, Angle As Double)
Private Function RotateP(ByRef x As Long, ByRef y As Long, ByRef Point As POINTAPI, Angle As Double) As POINTAPI
Dim Tmp1 As Double
Dim Tmp2 As Double
Tmp1 = Point.x - x
Tmp2 = Point.y - y
Point.x = Tmp1 * Cos(Angle) - Tmp2 * Sin(Angle)
Point.y = Tmp1 * Sin(Angle) + Tmp2 * Cos(Angle)
Point.x = Point.x + x
Point.y = Point.y + y
RotateP = Point
End Function
i have this project, and works... but when i try put in my project, like copy your functions and the variables, the code is ignored... but why the code is ignored?
thank you
question 2 how do u flip images like how do u get picMove1 to flip
Heres a simple way to flip an image inside a picture box.
Code:
Option Explicit
Private Declare Function StretchBlt Lib "gdi32" _
(ByVal hdc As Long, ByVal x As Long, ByVal y As Long, _
ByVal nWidth As Long, ByVal nHeight As Long, _
ByVal hSrcDC As Long, ByVal xSrc As Long, _
ByVal ySrc As Long, ByVal nSrcWidth As Long, _
ByVal nSrcHeight As Long, ByVal dwRop As Long) As Long
Private Const SRCCOPY = &HCC0020
Heres a simple way to flip an image inside a picture box.
Code:
Option Explicit
Private Declare Function StretchBlt Lib "gdi32" _
(ByVal hdc As Long, ByVal x As Long, ByVal y As Long, _
ByVal nWidth As Long, ByVal nHeight As Long, _
ByVal hSrcDC As Long, ByVal xSrc As Long, _
ByVal ySrc As Long, ByVal nSrcWidth As Long, _
ByVal nSrcHeight As Long, ByVal dwRop As Long) As Long
Private Const SRCCOPY = &HCC0020
thank you... thank you... but what i need is more complex... in Games and Graphics section one person is help me the rotation math...
thank you my friend...