The DelphiXE7 + GLscene source code which can be downloaded in http://www.cognitor.com.br/IsolinesSF.zip permit to create isolines in a PlaneXY from a set of 3D points. The plane can be moved and the isolines are created in each position of the plane. Just compile and run to see.
The GLcontouring.SFC.pas used in the code has differences from the GLcontouring.pas (GLscene site) just to permit writing the values of some of the isolines.
The code works but there are points that I could not solve ( a to c below) for which I need your help :
a) When we run the code, the isolines are showed correctly and the values are correctly written. I would like that the letters more easily visible but not increasing the font size. The font size is selected as a function of the size of the plane .
b) If I move the plane the fonts (TGlspacetext ) the isolines are redrawn correctly but the letters of the previous position of the plane remains there . Only the ones in the plane should be visible
c) When I close the program sometimes I get an error “Access violation”
d) Another welcome improvement would be to see the fonts from both sides of the plane – in the right position for reading
e) How could I do the panning of the screen in the horizontal or vertical position?
Historic in my previous post about Isolines
Thank you, in advance, for your help !
If anyone wants to write me directly, my email is sergiofeitoza@cognitor.com.br
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Dear Paul
Thank you. It works fine . Nice to work again with GLcontouring.pas intead of GLcontouringSFC.pas
Some finishings:
a) When we have the isolines very close together the GLspacetexts can superpose (see upper part of this attachment)
I tried inside Conrec a RandomRange in the GLSpaceText position as below . Not 100% but better than before
with GlspaceTextSF[K] do
begin
Scale.AsVector := VectorMake(scaleFont, scaleFont, scaleFont);
Material.FrontProperties.Emission.Color := clryellow;
Material.FrontProperties.Ambient.SetColor(1, 1, 1, 1);
b) When I run the test case Example1 works perfectly
Then I click Example2 case and it works well too but the previois GLspaceText are not deleted and remains there . Why ?
c) I am trying to do something to adpat better the size of the GLspace text depending of the size of the isoline
Hi Sergio,
I am looking for panning method and run the code in https://sourceforge.net/p/glscene/discussion/93606/thread/6dbf2dea/ described by "shine world", but it is not work correctly , when I move mouse , my camera position change in curve line slowly , I use TGLheightfield in my scene because I need to Z axis Up .
I download IsolinesSF.7z for check panning method but it has one error ( Undeclared Identifier TLineNodesAspect) and does not run , My Glscene version is 1.5.
can you help me ,
thank you.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The DelphiXE7 + GLscene source code which can be downloaded in http://www.cognitor.com.br/IsolinesSF.zip permit to create isolines in a PlaneXY from a set of 3D points. The plane can be moved and the isolines are created in each position of the plane. Just compile and run to see.
The GLcontouring.SFC.pas used in the code has differences from the GLcontouring.pas (GLscene site) just to permit writing the values of some of the isolines.
The code works but there are points that I could not solve ( a to c below) for which I need your help :
a) When we run the code, the isolines are showed correctly and the values are correctly written. I would like that the letters more easily visible but not increasing the font size. The font size is selected as a function of the size of the plane .
b) If I move the plane the fonts (TGlspacetext ) the isolines are redrawn correctly but the letters of the previous position of the plane remains there . Only the ones in the plane should be visible
c) When I close the program sometimes I get an error “Access violation”
d) Another welcome improvement would be to see the fonts from both sides of the plane – in the right position for reading
e) How could I do the panning of the screen in the horizontal or vertical position?
Historic in my previous post about Isolines
Thank you, in advance, for your help !
If anyone wants to write me directly, my email is sergiofeitoza@cognitor.com.br
New version working without errors
http://www.cognitor.com.br/IsolinesSF.zip
Sergio,
The GLContouring unit is fixed so you may use further the GLSViewer as interface better, e.g. adding a child form for isoline options.
PW
Dear Paul
Thank you. It works fine . Nice to work again with GLcontouring.pas intead of GLcontouringSFC.pas
Some finishings:
a) When we have the isolines very close together the GLspacetexts can superpose (see upper part of this attachment)
I tried inside Conrec a RandomRange in the GLSpaceText position as below . Not 100% but better than before
with GlspaceTextSF[K] do
begin
Scale.AsVector := VectorMake(scaleFont, scaleFont, scaleFont);
Material.FrontProperties.Emission.Color := clryellow;
Material.FrontProperties.Ambient.SetColor(1, 1, 1, 1);
here >>>> Position.AsVector := VectorMake((1+RandomRange(-15, 15)/100) * x1,
0.99 y1,
1.01Z_kfix);
StructureChanged;
end;
b) When I run the test case Example1 works perfectly
Then I click Example2 case and it works well too but the previois GLspaceText are not deleted and remains there . Why ?
c) I am trying to do something to adpat better the size of the GLspace text depending of the size of the isoline
Regards
Sergio
Hi Sergio,
I am looking for panning method and run the code in https://sourceforge.net/p/glscene/discussion/93606/thread/6dbf2dea/ described by "shine world", but it is not work correctly , when I move mouse , my camera position change in curve line slowly , I use TGLheightfield in my scene because I need to Z axis Up .
I download IsolinesSF.7z for check panning method but it has one error ( Undeclared Identifier TLineNodesAspect) and does not run , My Glscene version is 1.5.
can you help me ,
thank you.