Re: [Flightgear-devel] Material animation problems with osg

2007-10-20 Thread Ron Jensen
On Sat, 2007-10-20 at 17:28 -0600, Ron Jensen wrote:
> On Sat, 2007-10-20 at 18:24 +0100, Jon Stockill wrote:
> > Syd&Sandy wrote:
> > 
> > > I havent tested this one but Ive found that I have to put the material 
> > > animation first before any
> > > others for it to work  
> > 
> > It appears to be a bug in the osg version - changing bool to int and 
> > true/false to 1/0 makes everything work. Is plib doing a type conversion 
> > that osg isnt?
> > 
> > Jon
> 
> It sounds like that is the case, and its not unreasonable, IMHO, that
> you can't multiply a number by "false" and get a valid answer.
> 
> Have you tried something like this:
> 
>   
>material
>LED
> /instrumentation/elt/enabled
>
> 1
> 0
> 0
>
>   
> 
> 
> Ron

Nevermind, that didn't work at all for me.  However, I put your code
(more or less) into an instrument I have here and it did work under OSG.
The AvionicsToggle is a toggle switch model taken from
Aircraft/Instruments-3d/controls/switch-large-flat.ac.  It rotates with
the boolean property value as well.  I last built Simgear/Flightgear on
31 Aug and am using OSG 2.0:






switch-panel.ac


material
LED

0.9
0.0
0.0
controls/FIXME




rotate
AvionicsToggle
controls/FIXME
40

0.0
-1.0
0.0


 0.0
 0.0
-0.009




pick

Avionics Power Toggle
0

property-toggle
controls/FIXME


AvionicsToggle






-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Material animation problems with osg

2007-10-20 Thread Ron Jensen
On Sat, 2007-10-20 at 18:24 +0100, Jon Stockill wrote:
> Syd&Sandy wrote:
> 
> > I havent tested this one but Ive found that I have to put the material 
> > animation first before any
> > others for it to work  
> 
> It appears to be a bug in the osg version - changing bool to int and 
> true/false to 1/0 makes everything work. Is plib doing a type conversion 
> that osg isnt?
> 
> Jon

It sounds like that is the case, and its not unreasonable, IMHO, that
you can't multiply a number by "false" and get a valid answer.

Have you tried something like this:

  
   material
   LED
/instrumentation/elt/enabled
   
1
0
0
   
  


Ron

 


-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Material animation problems with osg

2007-10-20 Thread Jon Stockill
Syd&Sandy wrote:

> I havent tested this one but Ive found that I have to put the material 
> animation first before any
> others for it to work  

It appears to be a bug in the osg version - changing bool to int and 
true/false to 1/0 makes everything work. Is plib doing a type conversion 
that osg isnt?

Jon

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] Material animation problems with osg

2007-10-20 Thread
On Sat, 20 Oct 2007 15:53:14 +0100
Jon Stockill <[EMAIL PROTECTED]> wrote:

> I'm having problems with material animations under the osg version of 
> flightgear. Melchior has confirmed that it's working for him with the 
> plib version, and that the config is correct. It's an extremely somple 
> model that consists of 2 buttons that turn a light on and off, so the 
> xml looks like this:
> 
> 
> 
>   ELT.ac
> 
>   
>pick
>true
>Enable
>
> 0
> false
> 
>  property-assign
>  /instrumentation/elt/enabled
>  true
> 
>
>   
> 
>   
>pick
>true
>Reset
>
> 0
> false
> 
>  property-assign
>  /instrumentation/elt/enabled
>  false
> 
>
>   
> 
>   
>material
>LED
>
> 1
> 0
> 0
> /instrumentation/elt/enabled
>
>   
> 
> 
> 
> Clicking the Enable and Reset objects results in the relevant node being 
> toggled in the property tree, but the LED object is never illuminated.
> 
> Anyone got a fix, or a workaround?
> 
> Jon
> 

I havent tested this one but Ive found that I have to put the material 
animation first before any
others for it to work  

-- 
Syd&Sandy <[EMAIL PROTECTED]>

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


[Flightgear-devel] Material animation problems with osg

2007-10-20 Thread Jon Stockill
I'm having problems with material animations under the osg version of 
flightgear. Melchior has confirmed that it's working for him with the 
plib version, and that the config is correct. It's an extremely somple 
model that consists of 2 buttons that turn a light on and off, so the 
xml looks like this:



  ELT.ac

  
   pick
   true
   Enable
   
0
false

 property-assign
 /instrumentation/elt/enabled
 true

   
  

  
   pick
   true
   Reset
   
0
false

 property-assign
 /instrumentation/elt/enabled
 false

   
  

  
   material
   LED
   
1
0
0
/instrumentation/elt/enabled
   
  



Clicking the Enable and Reset objects results in the relevant node being 
toggled in the property tree, but the LED object is never illuminated.

Anyone got a fix, or a workaround?

Jon

-
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel