mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-06-05 07:58:16 +02:00
fpvectorial: Fixes a major error: Duplicated definitions of X, Y and Z coordinates and some height matrix generation fixes in the 3D example
git-svn-id: trunk@35572 -
This commit is contained in:
parent
2684641b15
commit
b16a2f8aea
@ -150,6 +150,7 @@ var
|
||||
lPage: TvVectorialPage;
|
||||
lFile: TFileStream;
|
||||
x, y: Integer;
|
||||
lRed: Word;
|
||||
begin
|
||||
lRasterImage := TvRasterImage.Create;
|
||||
lPage := VecDoc.GetPage(0);
|
||||
@ -160,7 +161,10 @@ begin
|
||||
|
||||
for x := 0 to 1023 do
|
||||
for y := 0 to 1023 do
|
||||
lFile.WriteByte(Byte(lRasterImage.RasterImage.Colors[x, y].Red div $FF));
|
||||
begin
|
||||
lRed := lRasterImage.RasterImage.Colors[x, y].Red;
|
||||
lFile.WriteByte(Byte(lRed div $FF));
|
||||
end;
|
||||
|
||||
lFile.Free;
|
||||
end;
|
||||
|
@ -184,7 +184,6 @@ type
|
||||
|
||||
TvEntityWithPen = class(TvEntity)
|
||||
public
|
||||
X, Y, Z: Double;
|
||||
{@@ The global Pen for the entire entity. In the case of paths, individual
|
||||
elements might be able to override this setting. }
|
||||
Pen: TvPen;
|
||||
@ -591,7 +590,7 @@ begin
|
||||
if lPos.X < 0 then lPos.X := 0;
|
||||
if lPos.Y < 0 then lPos.Y := 0;
|
||||
|
||||
lValue.Red := Round((lEntity.Z - APage.MinZ) * 256 / (APage.MaxZ - APage.MinZ));
|
||||
lValue.Red := Round((lEntity.Z - APage.MinZ) * $FFFF / (APage.MaxZ - APage.MinZ));
|
||||
lValue.Green := lValue.Red;
|
||||
lValue.Blue := lValue.Red;
|
||||
//lValue.alpha:=;
|
||||
|
Loading…
Reference in New Issue
Block a user