Page 1 of 2

Iso-Surface again

Posted: Wed Jun 25, 2008 12:09 pm
by 10547537
Thanks for your answer :

Ad 1. It is the problem :
in version 7.0 it worked ok

const
ColorPalette: array [00..15] of TColor =
(
$000000, $ff0000, $ff8000, $ffc000,
$ffff00, $c0ff00, $80ff00, $00ff00,
$00ff80, $00ffff, $00dfff, $00c0ff,
$00a0ff, $0080ff, $0060ff, $0000ff
);.
.
.
.

with Series1 do begin
ClearPalette;
PaletteStyle := psCustom;
Active := TRUE;
Clear;
UsePalette := TRUE;
UseColorRange := False;
for I := 0 to 15 do begin
AddPalette(20 + 5 * I, ColorPalette );
end;
end;

In version 8.0 there is an error;


Ad. 2 I want to uses Iso-surface as flat "map". (Viev3D = FALSE)
In this case I cannot paint the surface with
LeftAxis.Automatic := TRUE;
BottomAxis.Automatic := TRUE;

I have many tables like this below :

HOURS
71.0 72.0 68.0 66.0 64.0 70.0 74.0 65.0 71.0 67.0 73.0 75.0 73.0 76.0 71.0 69.0 72.0 79.0 72.0 68.0 69.0 73.0 70.0 73.0
M 83.0 74.0 81.0 69.0 69.0 73.0 73.0 72.0 72.0 80.0 80.0 72.0 74.0 73.0 77.0 78.0 77.0 83.0 70.0 81.0 69.0 74.0 84.0 77.0
O 65.0 70.0 71.0 77.0 77.0 78.0 79.0 68.0 66.0 68.0 69.0 69.0 68.0 69.0 68.0 67.0 74.0 77.0 80.0 80.0 77.0 67.0 64.0 66.0
N 66.0 75.0 61.0 73.0 66.0 70.0 68.0 72.0 61.0 54.0 54.0 62.0 64.0 57.0 60.0 63.0 52.0 71.0 58.0 59.0 61.0 50.0 57.0 69.0
T 49.0 44.0 53.0 54.0 51.0 56.0 56.0 49.0 37.0 43.0 45.0 51.0 45.0 47.0 46.0 52.0 49.0 47.0 58.0 49.0 49.0 44.0 57.0 53.0
H 55.0 56.0 51.0 81.0 71.0 69.0 73.0 60.0 45.0 45.0 45.0 48.0 54.0 49.0 56.0 53.0 50.0 61.0 64.0 50.0 48.0 65.0 47.0 45.0
S 74.0 72.0 69.0 62.0 53.0 57.0 55.0 49.0 36.0 37.0 45.0 53.0 59.0 49.0 48.0 48.0 44.0 45.0 40.0 44.0 44.0 48.0 43.0 54.0
56.0 54.0 62.0 51.0 51.0 56.0 58.0 53.0 63.0 47.0 43.0 39.0 47.0 54.0 45.0 49.0 50.0 51.0 64.0 58.0 68.0 59.0 60.0 54.0
77.0 76.0 78.0 72.0 75.0 76.0 75.0 74.0 68.0 65.0 61.0 58.0 61.0 63.0 66.0 71.0 70.0 72.0 69.0 71.0 65.0 77.0 80.0 71.0
80.0 79.0 86.0 80.0 83.0 87.0 87.0 85.0 86.0 72.0 74.0 70.0 65.0 69.0 69.0 77.0 79.0 88.0 84.0 81.0 79.0 82.0 87.0 81.0
74.0 74.0 77.0 81.0 73.0 70.0 76.0 75.0 74.0 78.0 78.0 78.0 77.0 75.0 69.0 73.0 74.0 68.0 79.0 70.0 74.0 77.0 75.0 77.0
74.0 67.0 72.0 71.0 72.0 75.0 74.0 80.0 72.0 76.0 81.0 77.0 79.0 77.0 84.0 82.0 81.0 84.0 72.0 74.0 73.0 75.0 75.0 71.0

What am I to set in this case to make it work ?
I tried to change X Axis labels from numbers to month names, but procedure
Series1.AddXYX (H, Val, M, MONTHS [M], clBlack) did not change anything.
May be I forgotten about something ?
Janusz

Posted: Wed Jun 25, 2008 12:58 pm
by narcis
Hi Janusz,

1. Code below works fine for me here using v8.03, which is currently in release candidate stage. I'll send you the URL to download it.

Code: Select all

procedure TForm1.FormCreate(Sender: TObject);
const
ColorPalette: array [00..15] of TColor =
(
$000000, $ff0000, $ff8000, $ffc000,
$ffff00, $c0ff00, $80ff00, $00ff00,
$00ff80, $00ffff, $00dfff, $00c0ff,
$00a0ff, $0080ff, $0060ff, $0000ff
);
var I: Integer;
begin
  with Series1 do begin
    ClearPalette;
    PaletteStyle := psCustom;
    Active := TRUE;
    Clear;
    UsePalette := TRUE;
    UseColorRange := False;

    for I := 0 to 15 do begin
      AddPalette(20 + 5 * I, ColorPalette [I]);
    end;

    FillSampleValues();
  end;
end;
Does it work fine at your end?

2. I recommend you to read "Tutorial 4 - Axis Control" for information on how to set axes values format and datetime format. You'll find the tutorials at TeeChart's program group created by the binary installers.

BTW: If you are posting a reply to an existing thread we'd appreciate if you replied at the same thread. This makes threads easier to follow for everyone.

Thanks in advance.

Posted: Thu Jun 26, 2008 11:50 am
by 10547537
Hi,
Now I have version 8.03.11357
ad. 1 About ColorPalette - is the same errror :cry:
I have checked that ColorPalette is in public section in TCustomAxisPanel
in TeEngine unit. It make an error "Range check error", because it is
seen "before" const ColorPalette.

About Isosurface 3D = TRUE, is OK (as it was before).
when Automatic = FALSE
with 3D = FALSE there is new error :
raised exception class Axis Exception with message
Axix Minimum must be <= Maximum.
X : Minimum = 1, Maximum 12
Z : Minimum = 0, Maximim = 23
when automatic = TRUE Axis are OK
but there is no surface. I don't know what am I to do else ?
Janusz

Posted: Thu Jun 26, 2008 12:38 pm
by narcis
Hi Janusz,

Could you please send us a simple example project we can run "as-is" to reproduce the problem here?

You can either post your files at news://www.steema.net/steema.public.attachments newsgroup or at our upload page.

Thanks in advance.

Isosurface

Posted: Sat Jul 05, 2008 10:59 am
by 10547537
Hi,
name of unit is SAWISO.PAS,
name of result is CONTOUR.BMP
1. I do not know why is the area empty betwen X=1 and X=2
and betwen Z=0 and Z=1 ?
2. What I am to change in this code to get isosurface ?
Janusz

Posted: Mon Jul 07, 2008 7:18 am
by narcis
Hi Janusz,

Would you be so kind to send SAWISO.DFM too?

Thanks in advance.

Isosurface again

Posted: Mon Jul 07, 2008 9:11 am
by 10547537
Hi,
Thank for your answer
I've sent file SAVISO.DFM
Janusz

Posted: Mon Jul 07, 2008 9:36 am
by narcis
Hi Janusz,

I'm afraid this is a known bug (TV52012634). This is a top priority item to be fixed for next releases.

isosurface again

Posted: Mon Jul 07, 2008 10:42 am
by 10547537
Hi,
So let mi know if it's something new in Contour and Isosurface.
About TIsosurface, I think, there is something wrong in MaxValue.
In my example : It plots only elements < 12 (months). Because every Y element > 12 it plots nothing. Try to do
MAP [H, M] := 0.1 * MAP [H, M] and you will see the difference
Janusz

Posted: Tue Jul 15, 2008 8:52 am
by narcis
Hi Janusz,

We have done some enhancements in TeeSurfa.pas. However it's not finished yet and needs more work. Anyway, I'll send you current TeeSurfa.pas so that you can check how it works at your end.

Isosurface

Posted: Tue Jul 15, 2008 10:16 am
by 10547537
Hi,
I have just used new version of Teesurface.
1. TCountourSeries is better (A will send you CONTOUR.BMP file)
2. TIsoSorface - no change
Thaks for the message
Janusz

Posted: Wed Jul 16, 2008 10:09 am
by narcis
Hi Janusz,

Thanks for the information. We'll investigate the issue again and try to find a definitive solution to it. We will get back to you when we have further news.

Posted: Thu Jul 17, 2008 11:57 am
by narcis
Hi Janusz,

As an update, we have found that using TeeSurfa.pas we sent you and setting IrregularGrid=true in the unit you set plots the series correctly:

Code: Select all

procedure TSawIsoForm.FormActivate(Sender: TObject);
var
   M, H, I : Byte;
begin
   with Chart1 do begin
      View3D := FALSE; {IT IS WHAT I HAVE CHANGED}
   end;
   with Series1 do begin
      Clear;
      IrregularGrid:=true;

//      for I := 0 to 15 do begin
//         AddPalette (5 * I, ColorPalette [I]);
//      end;
      {MONTHS}
      for M := 1 to 12 do begin
         {HOURS}
         for H := 00 to 23 do begin
            AddXYZ (H, MYMAP [M, H], M);
         end;
      end;
      Active := TRUE;
   end;
end;
Could you please try if it works fine at your end?

Thanks in advance.

Isosurface

Posted: Fri Jul 18, 2008 7:23 pm
by 10547537
Hi,
Tcontourseries is OK. I sent bmp file today - thanks. Now I wait for something new about TIsosurface...
Janusz

Posted: Mon Jul 21, 2008 10:58 am
by narcis
Hi Janusz,

Thanks for the information.
Now I wait for something new about TIsosurface
Ok, I think this has an additional issue to the ones already fixed for Contour series. I've added it (TV52013255) to the bug list to be fixed for next releases.