[GRASS5] NVIZ updates

Bob Covill bcovill at tekmap.ns.ca
Fri Nov 14 08:25:07 EST 2003


Helena,

This seems to be a bit of a mystery. There is nothing new with the 
calculation of normals in the new release. The only thing I changed 
(removed) was the forced recalculation of normals if the z-exag. was 
changed. This was not necessary as the z-exag. is not used in the 
calculation.

The new coarse surface is simply a sub-sampling of the full resolution 
surface. It simply goes through the current full res. surface picking up 
the elevation and associated normal at the specified interval (mesh 
resolution).

I am wondering if the problem you are experiencing is in the actual 
coarse surface drawing loop? Some sort of mathmatical overrun with a 
certain combination of surface and mesh resolutions?

Would it be possible to get a bit more information on the projection, 
current region, and map type. A sample of the problem data would also be 
quite helpful.

--

Bob Covill

Helena wrote:
> Bob,
> 
> It crashes at 1m and 2m resolution, it runs fine with the same file with 
> 10m resolution,
> it starts OK with 5m or 3m resolution but crashes when I change the grid 
> size parameter from 1 to 4.
> It will run OK if I increase the grid parameter and change to mesh - so 
> it seems that the problem
> is with computation of normals for the coarse surface.
> 
> I hope that this helps to find the fix,
> 
> Helena
> 
> menubar made
> bgerror failed to handle background error.
>     Original error: too many nested calls to Tcl_Eval (infinite loop?)
>     Error in bgerror: too many nested calls to Tcl_EvalObj (infinite loop?)
> bgerror failed to handle background error.
>     Original error: too many nested calls to Tcl_Eval (infinite loop?)
>     Error in bgerror: too many nested calls to Tcl_EvalObj (infinite loop?)
> child killed: segmentation violation
>     while executing
> "exec /home/helena/grasscvs53/grass5/etc/nviz2.2/NVWISH2.2 -f 
> /home/helena/grasscvs53/grass5/etc/nviz2.2/scripts/nviz2.2_script 
> lidar99 -name NVIZ >&@s..."
>     ("eval" body line 1)
>     invoked from within
> "eval exec $env(GISBASE)/etc/nviz2.2/NVWISH2.2 -f 
> $env(GISBASE)/etc/nviz2.2/scripts/nviz2.2_script $argv -name NVIZ 
>  >&@stdout"
>     invoked from within
> "if {$argv == ""} {
> #no arguments
> eval exec $env(GISBASE)/etc/nviz2.2/NVWISH2.2 -f 
> $env(GISBASE)/etc/nviz2.2/scripts/nviz2.2_script -name NVIZ >&@stdo..."
>     (file "/home/helena/grasscvs53/grass5/bin/nviz" line 16)
> 
> bgerror failed to handle background error.
>     Original error: too many nested calls to Tcl_Eval (infinite loop?)
>     Error in bgerror: too many nested calls to Tcl_EvalObj (infinite loop?)
> bgerror failed to handle background error.
>     Original error: too many nested calls to Tcl_Eval (infinite loop?)
>     Error in bgerror: too many nested calls to Tcl_EvalObj (infinite loop?)
> bgerror failed to handle background error.
>     Original error: too many nested calls to Tcl_EvalObj (infinite loop?)
>     Error in bgerror: too many nested calls to Tcl_Eval (infinite loop?)
> 
> 
> Helena wrote:
> 
>> I should have done more before writing - it runs OK with Spearfish
>> and the new option with coarse rendered grid is realy,realy nice.
>> So I will try to find out why it crashes with the other data, maybe 
>> others can try too.
>>
>> Helena
>>
>> Helena wrote:
>>
>>> Bob,
>>>
>>> I updated my CVS GRASS with your nviz updates and nviz crashes
>>> when I give it an elevation file - either on the command line or
>>> through the interface - when it is computing the normals.
>>> It runs OK if I open it as nviz -q and give it just a constant 
>>> (plane) surface.
>>> I will try with some other data, but maybe somebody else could try it 
>>> too
>>> to see whether it is my data or a bug. (the data worked fine with the 
>>> previous
>>> version of nviz).
>>>
>>> Also, how do you have this linked with GRASS5.7 - are you maintaining 
>>> two separate versions?
>>>
>>>
>>> thank you,
>>>
>>> Helena
>>>
>>> Loading Data
>>> Loading Data
>>> translating colors from fp
>>> global-exag = 1.000000
>>> recalculating normals...
>>> 100
>>> 200
>>> child killed: segmentation violation
>>>     while executing
>>> "exec /home/helena/grasscvs53/grass5/etc/nviz2.2/NVWISH2.2 -f 
>>> /home/helena/grasscvs53/grass5/etc/nviz2.2/scripts/nviz2.2_script -q 
>>> -name NVIZ >&@stdout"
>>>     ("eval" body line 1)
>>>     invoked from within
>>> "eval exec $env(GISBASE)/etc/nviz2.2/NVWISH2.2 -f 
>>> $env(GISBASE)/etc/nviz2.2/scripts/nviz2.2_script $argv -name NVIZ 
>>>  >&@stdout"
>>>     invoked from within
>>> "if {$argv == ""} {
>>> #no arguments
>>> eval exec $env(GISBASE)/etc/nviz2.2/NVWISH2.2 -f 
>>> $env(GISBASE)/etc/nviz2.2/scripts/nviz2.2_script -name NVIZ >&@stdo..."
>>>     (file "/home/helena/grasscvs53/grass5/bin/nviz" line 16)
>>>
>>>
>>>
>>>
>>>
>>>  The error message Bob Covill wrote:
>>>
>>>> Hello,
>>>>
>>>> I have applied a few updates / bug fixes to the ogsf library and 
>>>> NVIZ. The updates / fixes include the following:
>>>>
>>>> 1. I have optimized the surface rendering routine to use a 
>>>> TRIANGLE_FAN along with a few other optimizations. In the tests I 
>>>> ran this improved surface drawing time by about a factor of four. 
>>>> This of course depends upon the surface being renderred and the zoom 
>>>> level.
>>>>
>>>> 2. I have added a new wire frame option (now the default) that draws 
>>>> a sub-sampled (coarse) surface instead of the wire. To accomadate 
>>>> this I have re-arranged the surface panel and added the drawing 
>>>> options as pull-down menus. There is now a pull-down menu for the 
>>>> old "Surface Style" and "Shading" options plus the new option for 
>>>> "Grid Style". Under "Grid Style" the user may now select to draw the 
>>>> coarse surface or the old wire surface. In reference to the new 
>>>> coarse surface, the resolution is controlled by the "Grid 
>>>> Resolution" number. This number represents the sub-sampling ratio of 
>>>> the current surface. A Grid Resolution of 1 would draw every 
>>>> (identical) full surface pixel. A Grid Resolution of 2 would draw 
>>>> every second pixel, and so on. This new drawing routine also allows 
>>>> animations to run in this coarse mode.
>>>>
>>>> 3. I have added a new "position" panel to the available panels list 
>>>> (under Panel). This new panel allows the user to manually enter the 
>>>> center and eye positions (XYZ) in real coordinates and apply them. 
>>>> There is also an available Range/Bearing section that allows the 
>>>> user to set a range and bearing to either the cente or eye positions.
>>>>
>>>> To use the menu select the Refresh button to update each entry box 
>>>> to the current position. To apply newly entered coordinates and and 
>>>> update the GUI select the Apply button. To use the Range/Bearing 
>>>> options select the Refesh button (if not already selected), and 
>>>> choose the appropriate reference radiobutton. The options are to 
>>>> apply range and bearing to "Eye to Surface" which moves the view 
>>>> center while leaving the eye position unchanged or "Surface to Eye" 
>>>> which changes the eye position while leaving the center position 
>>>> unchanged. The second "Surface to Eye" option is alittle easier to 
>>>> use as you are less likly to move the surface completely out of 
>>>> view. After choosing the appropriate reference enter a new Range, 
>>>> Bearing (in degrees) and Elevation (in degrees). The elevation sets 
>>>> the angle you are looking down at the surface. After entering the 
>>>> new values select Calculate to generate the new coordinates and 
>>>> Apply to the apply new coordinates.
>>>>
>>>> This new menu will probably need further updating / debugging.
>>>>
>>>> 4. I have fixed a couple of bugs in the kanimator panel where the 
>>>> new key time was not being set correctly and duplicate key tags were 
>>>> not being weeded out. The duplicate key tags led to unpredictable 
>>>> behavious in the kanimator GUI.
>>>>
>>>>
>>>> If you have any questions or problems with the above updates please 
>>>> let know.
>>>>
>>>
>>>
>>> _______________________________________________
>>> grass5 mailing list
>>> grass5 at grass.itc.it
>>> http://grass.itc.it/mailman/listinfo/grass5
>>




More information about the grass-dev mailing list