Re: [Flightgear-devel] [Flightgear-cvslogs] CVS: source/src/Main viewmgr.cxx, 1.42, 1.43 viewmgr.hxx, 1.19, 1.20

2009-11-11 Thread Erik Hofman
Csaba Halász wrote:
 On 5 Nov 2009, at 09:18, Erik Hofman wrote:
 
 John Denker:
 Add a view debugging functions and represent the viewer quats in the
 property tree for debugging.
 
 Unfortunately the debug code is broken and causes segfaults. It is
 tieing temporary char pointers to property nodes. In its current
 incarnation this happens in the function format_rotor in viewmgr.cxx.
 If we wish to have these debug properties I suggest they be published
 as numeric components.

Ok they are now placed as doubles under /sim/current-view/debug instead.

Erik

--
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] [Flightgear-cvslogs] CVS: source/src/Main viewmgr.cxx, 1.42, 1.43 viewmgr.hxx, 1.19, 1.20

2009-11-11 Thread John Denker
On 11/10/2009 06:36 PM, Csaba Halász wrote:
 On 5 Nov 2009, at 09:18, Erik Hofman wrote:
 
 John Denker:
 Add a view debugging functions and represent the viewer quats in the
 property tree for debugging.
 
 Unfortunately the debug code is broken and causes segfaults. It is
 tieing temporary char pointers to property nodes. In its current
 incarnation this happens in the function format_rotor in viewmgr.cxx.
 If we wish to have these debug properties I suggest they be published
 as numeric components.

That's interesting.  

In an earlier version, I did exactly that:  putting the quats
into the property tree as four separate numerical entries.

Before switching to the string representation, I read the
code for the tie functions.  I got the impression the code
was making a clone, i.e. a deep copy.  Apparently this
impression was incorrect.  Sorry.

Having used the feature both ways, I remain of the opinion
that the string representation is easier for the user to
interpret.  Doing this safely via a few static char*s is
easy to do.  Let me work on it.

--
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] [Flightgear-cvslogs] CVS: source/src/Main viewmgr.cxx, 1.42, 1.43 viewmgr.hxx, 1.19, 1.20

2009-11-11 Thread Csaba Halász
On Wed, Nov 11, 2009 at 2:43 PM, John Denker j...@av8n.com wrote:

 Before switching to the string representation, I read the
 code for the tie functions.  I got the impression the code
 was making a clone, i.e. a deep copy.  Apparently this
 impression was incorrect.  Sorry.

No, the problem isn't with the property tree. You were returning the
c_str() from a string that goes out of scope when the format_rotor
function exits. Thus, the returned pointer will already be invalid
when it gets passed to the tie.

-- 
Csaba/Jester

--
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] [Flightgear-cvslogs] CVS: source/src/Main viewmgr.cxx, 1.42, 1.43 viewmgr.hxx, 1.19, 1.20

2009-11-11 Thread Erik Hofman
John Denker wrote:
 Having used the feature both ways, I remain of the opinion
 that the string representation is easier for the user to
 interpret.  Doing this safely via a few static char*s is
 easy to do.  Let me work on it.

To be honest I don't think it's worth the effort, but I wont hold you back.

Erik

--
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] [Flightgear-cvslogs] CVS: source/src/Main viewmgr.cxx, 1.42, 1.43 viewmgr.hxx, 1.19, 1.20

2009-11-11 Thread John Denker
On 11/11/2009 07:10 AM, Erik Hofman wrote:
 John Denker wrote:
 Having used the feature both ways, I remain of the opinion
 that the string representation is easier for the user to
 interpret.  Doing this safely via a few static char*s is
 easy to do.  Let me work on it.
 
 To be honest I don't think it's worth the effort, but I wont hold you back.

Done already:
  http://www.av8n.com/fly/fgfs/quat-no-stack.patch


--
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] [Flightgear-cvslogs] CVS: source/src/Main viewmgr.cxx, 1.42, 1.43 viewmgr.hxx, 1.19, 1.20

2009-11-10 Thread Csaba Halász
On 5 Nov 2009, at 09:18, Erik Hofman wrote:

 John Denker:
 Add a view debugging functions and represent the viewer quats in the
 property tree for debugging.

Unfortunately the debug code is broken and causes segfaults. It is
tieing temporary char pointers to property nodes. In its current
incarnation this happens in the function format_rotor in viewmgr.cxx.
If we wish to have these debug properties I suggest they be published
as numeric components.

-- 
Csaba/Jester

--
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel