Questions tagged [tbitmap]
50 questions
1
vote
3 answers
How change the alpha value of a specific color in a 32 bit TBitmap?
I need to change the value of the alpha component when a pixel contains a specific color for a TBitmap of 32 bits, I know about the ScanLine property to access the bitmap data, but i can't figure out how change the alpha component of each pixel.

Salvador
- 16,132
- 33
- 143
- 245
0
votes
1 answer
TBitmap LoadFromResourceName is not working
I am using C++Builder. I have 70 small bitmap images in a .res file.
My code using MyBitMap->LoadFromResourceID works and loads the bitmap from the .res file.
TBitmap *MyBitMap = new Graphics::TBitmap();
MyBitMap->LoadFromResourceID(…

WorldTalk
- 13
- 2
0
votes
1 answer
How do I make a TBitmap transparent when loading it from a resource
I am trying to load a TBitmap from resources while keeping it transparent. Even with the transparent Property enabled it still looks the same.
What I tried to do:
procedure TMovie.BitBtn1Click(Sender: TObject);
var
BitMap1 : TBitMap;
begin
…

Codex
- 101
- 1
- 11
0
votes
0 answers
Equivalent of vcl DrawEdge in FMX
I'm trying to write an equivalent of FMX UI to replace the VCL.
What's the equivalent of DrawEdge in FMX cross-platform for these functions? (or nearest equivalent, if it cannot be the same)
var lRect: TRect;
DrawEdge(FBitmap.Canvas.Handle, lRect,…

Peter Jones
- 451
- 2
- 12
0
votes
1 answer
How to Assign a TBitmap to a TPath.Data
I would like to fill a TPath.Data from a TBitmap.
Delphi FMX provides a FillPath on a Bitmap Canvas:-
http://docwiki.embarcadero.com/CodeExamples/Rio/en/FMXTCanvasFillFunctions_(Delphi)
Image1.Bitmap.Canvas.FillPath(path, 200);
But I'm looking fill…

Yuppski
- 137
- 2
- 10
0
votes
0 answers
Delphi rendering Direct3D to a Bitmap instead of screen
I'm new at Delphi direct3D. Finally got some basic framework up and running rendering 2 triangles to the screen. Works. However I would like it rendered now to a Tbitmap.
After 2 days of searching I have not found any example online.. maybe someone…

hall9000
- 1
0
votes
1 answer
Clear a TBitmap before changing it in Delphi (VCL/Windows)
This is about Delphi, 32 bits and Windows/VCL:
For a procedure that takes an input bitmap and writes to an output bitmap with a given format (PixelFormat: pf8Bit with a gray scale palette) I use the following code:
procedure ConvertBitmap(_inBmp:…

dummzeuch
- 10,975
- 4
- 51
- 158
0
votes
2 answers
How to use Image1.Bitmap.BitmapChanged;
Bitmap.BitmapChanged; is protected in FMX.Graphics so I cannot use the procedure.
Useing a TImage or TImageControler I am drawing a line but the line does not show.
I am using this…

GreatDayDan
- 169
- 4
- 16
0
votes
1 answer
White image when resizing Tbitmap
This code is supposed to resize a TBitmap, but the resulting bitmap is just a white image (with the final size). I'm using it to resize to a lower size.
function ResizeBitmap(B: TBitmap; Width, Height: Integer): TBitmap;
var
finalbitmap:…

Bazi
- 37
- 4
0
votes
2 answers
C++ builder transparent bitmaps cover the canvas
In the OnPaint event of a TForm, I want to paint bitmaps that do not cover the background or other painted object because they have transparent parts.
If I draw an image over an image, it works.
But when I draw on the Form's Canvas, it does not…

Lotfi
- 660
- 1
- 6
- 21
0
votes
1 answer
CreateDIBitmap: black image captured
I had build part of this code below based in this C++ example where the goal is make a screenshot without the main form appear on capture.
My trouble is because i'm getting a black screen captured by following code:
function…
user9214428
0
votes
1 answer
Rotating a square TBitmap on its center
I am trying to find the simplest way to rotate and display a TBitmap on its center by any given angle needed. The TBitmap is square and any clipping that might occur is not important so long as the rotated bitmap's center point remains constant. …

Jim
- 45
- 7
0
votes
1 answer
How to convert NSImage to FireMonkey TBitmap?
How to convert an NSImage to Delphis FireMonkey TBitmap? The NSImage is being passed to me from an Objective C API. I am using Delphi XE8.

Nader
- 47
- 1
- 8
0
votes
1 answer
Increasing the size or depth of a TBitmap
When I increase the size of a bitmap by (for example) ...
bitmap.Width := bitmap.Width + 30;
... do I have any control of what the right-hand 30 pixels get filled with, or do I just assume they're uninitialized
Similarly if I change PixelFormat…

Roddy
- 66,617
- 42
- 165
- 277
0
votes
1 answer
Default value of PixelFormat for Graphics.TBitmap in Delphi
What is the default value of PixelFormat for TBitmap in Delphi?
Do I need to specify PixelFormat everytime I create TBitmap?
For example,
var
img: TBitmap;
begin
img := TBitmap.Create;
img.PixelFormat := pf32bit; // or pf24bit?
...
…

justyy
- 5,831
- 4
- 40
- 73