我想用vb实现图像的压缩例如压缩为384*288
要指定高和宽的压缩才给分
分不够我可以加
要指定高和宽的压缩才给分
分不够我可以加
解决方案 »
- 可以为组合框(combox)设定默认选项吗?
- 本人离职 需要找一人继续做我的工作 需求 见内容
- vb中有没有把整数和小数的位数进行分割的函数
- datareport问题(我在里面只画一个线条,其他什么也没有,datasource怎么设置)
- 画线问题,请高手指点
- vb求助
- 菜鸟高分求解:怎样在picturebox中画一条平滑斜线;放大时怎样消除锯齿
- 我写了一个DLL利用WINSOCK发送数据,EXE接收,可速度很慢,为什么啊
- 十万火急!高手请进,请问,怎么把帮助文件与应用程序连到一起?
- 问一个DATAGRID的问题,盼解答!
- 这个控件怎么不能拖动啊
- 有谁知道 如何用VB开发WORD的.WLL插件?
或到http://cwsoft.y365.com/图像压缩.rar 下载VERSION 5.00
Begin VB.Form Form1
Caption = "Form1"
ClientHeight = 6960
ClientLeft = 60
ClientTop = 450
ClientWidth = 10425
LinkTopic = "Form1"
ScaleHeight = 464
ScaleMode = 3 'Pixel
ScaleWidth = 695
StartUpPosition = 3 '窗口缺省
Begin VB.CommandButton Command1
Caption = "压缩"
Height = 975
Left = 7680
TabIndex = 4
Top = 4800
Width = 1935
End
Begin VB.TextBox Text2
Height = 270
Left = 7560
TabIndex = 3
Text = "100"
Top = 960
Width = 1695
End
Begin VB.TextBox Text1
Height = 270
Left = 7560
TabIndex = 2
Text = "100"
Top = 600
Width = 1695
End
Begin VB.PictureBox Picture2
AutoRedraw = -1 'True
AutoSize = -1 'True
Height = 2055
Left = 7560
ScaleHeight = 133
ScaleMode = 3 'Pixel
ScaleWidth = 149
TabIndex = 1
Top = 2160
Width = 2295
End
Begin VB.PictureBox Picture1
AutoRedraw = -1 'True
AutoSize = -1 'True
Height = 6555
Left = 360
Picture = "Form1.frx":0000
ScaleHeight = 433
ScaleMode = 3 'Pixel
ScaleWidth = 467
TabIndex = 0
Top = 240
Width = 7065
End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
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 LongPrivate Sub Command1_Click()
Picture2.Width = Text1.Text
Picture2.Height = Text2.Text
StretchBlt Picture2.hdc, 0, 0, Val(Text1.Text), Val(Text2.Text), Picture1.hdc, 0, 0, Picture1.ScaleWidth, Picture1.ScaleHeight, vbSrcCopy
Picture2.Refresh
End Sub