mirror of
https://github.com/NGSolve/netgen.git
synced 2024-11-11 16:49:16 +05:00
visualization of vector functions, internal representation
This commit is contained in:
parent
2374ec9782
commit
a4dcf70c69
@ -4278,7 +4278,7 @@ namespace netgen
|
|||||||
vssolution.fieldlines_vecfunction = -1;
|
vssolution.fieldlines_vecfunction = -1;
|
||||||
|
|
||||||
int pointpos; // SZ
|
int pointpos; // SZ
|
||||||
const char * pch = strchr(scalname,'.');
|
const char * pch = strchr(scalname,':');
|
||||||
pointpos = int(pch-scalname+1);
|
pointpos = int(pch-scalname+1);
|
||||||
|
|
||||||
for (int i = 0; i < vssolution.soldata.Size(); i++)
|
for (int i = 0; i < vssolution.soldata.Size(); i++)
|
||||||
@ -4293,7 +4293,7 @@ namespace netgen
|
|||||||
char newscalname[100];
|
char newscalname[100];
|
||||||
for ( int ii = 0; ii < pointpos; ii++ )
|
for ( int ii = 0; ii < pointpos; ii++ )
|
||||||
newscalname[ii] = scalname[ii];
|
newscalname[ii] = scalname[ii];
|
||||||
newscalname[pointpos] = '.';
|
newscalname[pointpos] = ':';
|
||||||
sprintf (newscalname+pointpos, "%i", vssolution.scalcomp);
|
sprintf (newscalname+pointpos, "%i", vssolution.scalcomp);
|
||||||
|
|
||||||
if (strcmp (scalname, newscalname) != 0)
|
if (strcmp (scalname, newscalname) != 0)
|
||||||
|
@ -1257,12 +1257,12 @@ proc visual_dialog { } {
|
|||||||
set fname [Ng_Vis_Field getfieldname $i]
|
set fname [Ng_Vis_Field getfieldname $i]
|
||||||
set fcomp [Ng_Vis_Field getfieldcomponents $i]
|
set fcomp [Ng_Vis_Field getfieldcomponents $i]
|
||||||
if { $fcomp == 1 } {
|
if { $fcomp == 1 } {
|
||||||
$w.scalfun add command $fname.1 -label $fname
|
$w.scalfun add command $fname:1 -label $fname
|
||||||
} {
|
} {
|
||||||
for { set j 1 } { $j <= $fcomp } { incr j } {
|
for { set j 1 } { $j <= $fcomp } { incr j } {
|
||||||
$w.scalfun add command $fname.$j -label "$fname ($j)"
|
$w.scalfun add command $fname:$j -label "$fname ($j)"
|
||||||
}
|
}
|
||||||
$w.scalfun add command $fname.0 -label "func ($fname)"
|
$w.scalfun add command $fname:0 -label "func ($fname)"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user