sorinara |
Posted - Sep 01 2024 : 11:29:25 Problem: i’ve created a code in ImageEnView where an image from the ImageEnView is copied, and a new layer is created with that copied image. The layer can be moved and its transparency adjusted to compare it with the original image. However, when i move the layer with the mouse, the background color of the duplicated image layer changes to black.
ex) ImageEnView.Layers[idx].Bitmap.Fill(clwhite); ImageEnView.Layers[idx].UserData := SImage; ImageEnView.Layers[idx].PosX := ImageEnView.ViewX; ImageEnView.Layers[idx].PosY := ImageEnView.ViewY;
ImageEnView.LayerOptions := ImageEnView.LayerOptions + [loAllowMultiSelect,loAutoSelectMask]; ImageEnView.MouseInteractLayers :=[miMoveLayers,miRotateLayers]; ImageEnView.LayerDefaults.Clear;
ImageEnView.IO.NativePixelFormat := True; ImageEnView.IO.LoadFromStream(FImage); ImageEnView.CurrentLayer.Transparency := TrackBar1.Position;
ImageEnView.IEBitmap.ChannelOffset[0] := 10; ImageEnView.IEBitmap.ChannelOffset[1] := 0; ImageEnView.IEBitmap.ChannelOffset[2] := 0;
ImageEnView.LayersCurrent := idx; ImageEnView.Layers[idx].AntiAlias := False; ImageEnView.Layers[idx].ResampleFilter := rfFastLinear; ImageEnView.LayersDrawBox := True; |