Rank: Advanced Member
Groups: Guest
Joined: 3/3/2008(UTC) Posts: 185
Thanks: 8 times
|
Hi, I am trying to add mask to my image, and I would like to make an undo and redo for it. I tried those sample from the internet but still can't get it work. anyway could give me a better idea on it please? Thanks. Code: _bmViewer.Bitmap.UndoRedoEnabled = False
'Dim UserImage As Aurigma.GraphicsMill.Bitmap = _bmViewer.Bitmap
Dim UserImage As New Aurigma.GraphicsMill.Bitmap(_bmViewer.Bitmap)
Dim _item As Aurigma.GraphicsMill.WinControls.ThumbnailListItem
_item = _thlMask.SelectedItems(0)
Dim MaskImage As New Aurigma.GraphicsMill.Bitmap(_item.Pidl.Path)
Dim resultImage As New Aurigma.GraphicsMill.Bitmap(UserImage.Width, UserImage.Height, Aurigma.GraphicsMill.PixelFormat.Format32bppArgb)
' Mask Preperation
MaskImage.HorizontalResolution = UserImage.HorizontalResolution
MaskImage.VerticalResolution = UserImage.VerticalResolution
MaskImage.Transforms.Resize(UserImage.Width, UserImage.Height, Transforms.ResizeMode.Resize)
If MaskImage.PixelFormat <> PixelFormat.Format8bppGrayScale Then
MaskImage.ColorManagement.Convert(PixelFormat.Format8bppGrayScale)
End If
resultImage.HorizontalResolution = UserImage.HorizontalResolution
resultImage.VerticalResolution = UserImage.VerticalResolution
resultImage.Transforms.Resize(UserImage.Width, UserImage.Height, Transforms.ResizeMode.Resize)
resultImage = ManualCombine(UserImage, MaskImage)
_bmViewer.Bitmap = resultImage
_bmViewer.Bitmap.UndoRedoEnabled = True
_bmViewer.Bitmap.SaveState()
_btnUndo.Enabled = True
Edited by user Friday, March 14, 2008 11:57:23 PM(UTC)
| Reason: Not specified
|
|
|
|
Rank: Advanced Member
Groups: Guest
Joined: 1/31/2005(UTC) Posts: 458
Was thanked: 5 time(s) in 5 post(s)
|
Hello, I am afraid that it will be hard to help you having only this part of code. For example, I cannot find any Undo() or Redo() calls. Could you submit case with a complete sample project? I will do my best to assist you with this issue. Edited by user Thursday, May 22, 2008 2:16:43 PM(UTC)
| Reason: Not specified |
|
|
|
|
Rank: Advanced Member
Groups: Guest
Joined: 3/3/2008(UTC) Posts: 185
Thanks: 8 times
|
Hi, The sample project is a bit too big to send via Email. I already upload the files to our webserver and emailed the URL detail to you. Please confirm. Thanks.
|
|
|
|
Rank: Advanced Member
Groups: Guest
Joined: 1/31/2005(UTC) Posts: 458
Was thanked: 5 time(s) in 5 post(s)
|
Hi, OK, I have received the URL and downloaded the sample. I will answer you by email. |
|
|
|
|
Rank: Advanced Member
Groups: Guest
Joined: 3/3/2008(UTC) Posts: 185
Thanks: 8 times
|
Okay. Thanks. Will be waiting for it...
|
|
|
|
Rank: Advanced Member
Groups: Guest
Joined: 1/31/2005(UTC) Posts: 458
Was thanked: 5 time(s) in 5 post(s)
|
Hi, I have answered you by email. Please post here a line if you have not got the message. Edited by user Friday, March 14, 2008 5:21:32 PM(UTC)
| Reason: Not specified |
|
|
|
|
Rank: Advanced Member
Groups: Guest
Joined: 3/3/2008(UTC) Posts: 185
Thanks: 8 times
|
Alex Kon wrote:Hi, I have answered you by email. Please post here a line if you have not got the message. Thanks for the solution. It works great !!!
|
|
|
|
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.