I got problem with program in VB. It scale picture in picterebox. On windows work fine but on wine 1.6-rc5 it save bad image.
It show good image in picturebox but save bad.
Code: Select all
PictureBox1.Image = Image.FromFile(zrodlo)
Dim source As Bitmap = PictureBox1.Image
Dim dest_image As New Bitmap(80, 70)
Dim g As Graphics = Graphics.FromImage(dest_image)
Using objImage As System.Drawing.Image = System.Drawing.Image.FromFile(zrodlo)
' Display its Height and Width
Dim scale As Double = objImage.Height / objImage.Width
Dim width As Integer = Convert.ToInt32(dest_image.Height / scale)
width = Int((width * 10 ^ 0) + 0.5) / 10 ^ 0
Dim przesuniecie As Integer = Convert.ToInt32((dest_image.Width - width) / 2)
g.DrawImage(source, przesuniecie, 0, width, dest_image.Height + 1)
PictureBox1.Image = dest_image
End Using
Dim image2 As Image = dest_image
image2.Save(My.Settings.dir4 + nazwa_zdjecia.Text, System.Drawing.Imaging.ImageFormat.Jpeg)
Windows/wine conv:

Anyone got some idea how to fix this?