Board index FlightGear Development Aircraft

Animation of the objects  Topic is solved

Questions and discussion about creating aircraft. Flight dynamics, 3d models, cockpits, systems, animation, textures.

Animation of the objects

Postby V12 » Tue Sep 19, 2017 4:22 pm

I have problem with knob animation. I want use syntax :
Code: Select all
.
.
.
<axis>
    <object-name>some-object</object-name>
</axis>


but this doesn't work and my knob not rotate along designated axis. Where is problem ? Does works this FG 2017.2x feature ?
Fly high, fly fast - fly Concorde !
User avatar
V12
 
Posts: 1289
Joined: Thu Jan 12, 2017 4:27 pm
Location: LZIB
Callsign: BAWV12

Re: Animation of the objects

Postby Richard » Tue Sep 19, 2017 6:24 pm

It's a 2017.2 feature, as far as I can tell it works fine.

Paste the actual example together with a screenshot of the object you are using for the axis. The object that you use for the axis must have exactly two vertices.

see http://wiki.flightgear.org/Howto:Animate_models#Using_a_geometry_object_for_axis_and_centre_.282017.2.29
Richard
 
Posts: 689
Joined: Sun Nov 02, 2014 10:17 pm
Version: Git
OS: Win10

Re: Animation of the objects  

Postby V12 » Tue Sep 19, 2017 7:26 pm

I did it, but didn't work. When renamed axis object in the animation, knob rotate as before axis rename :(
Fly high, fly fast - fly Concorde !
User avatar
V12
 
Posts: 1289
Joined: Thu Jan 12, 2017 4:27 pm
Location: LZIB
Callsign: BAWV12

Re: Animation of the objects

Postby Richard » Tue Sep 19, 2017 9:54 pm

just to be clear you have two objects.

I name this object and object-axis.

Like this. Image

and the animation is like this

Code: Select all
  <animation>
    <type>knob</type>
    <object-name>hud-vert-datum-knob</object-name>
    <property>controls/hud/vert-datum</property>
    <factor>20</factor>
    <axis>
      <object-name>hud-vert-datum-knob-axis</object-name>
    </axis>
    <action>
      <binding>
        <command>property-adjust</command>
        <property>controls/hud/vert-datum</property>
        <factor>1</factor>
        <min>0</min>
        <max>9</max>
        <wrap>false</wrap>
      </binding>
    </action>
  </animation>
Richard
 
Posts: 689
Joined: Sun Nov 02, 2014 10:17 pm
Version: Git
OS: Win10

Re: Animation of the objects

Postby Necolatis » Tue Sep 19, 2017 10:36 pm

I guess if you export the object from Blender, you should check that it should export lines too, normally it only export faces (at least the exporter I work on, don't know what you use).
"Airplane travel is nature's way of making you look like your passport photo."
— Al Gore


Hangar: https://sites.google.com/site/fghangar/
User avatar
Necolatis
 
Posts: 1907
Joined: Mon Oct 29, 2012 12:40 am
Location: EKOD
Callsign: Leto
IRC name: Neco
Version: 2018.3.2
OS: Windows 10

Re: Animation of the objects

Postby Richard » Tue Sep 19, 2017 11:16 pm

that might be the problem. maybe try with a small triangle.
Richard
 
Posts: 689
Joined: Sun Nov 02, 2014 10:17 pm
Version: Git
OS: Win10

Re: Animation of the objects

Postby V12 » Wed Sep 20, 2017 3:54 am

My Blender exported axis, I checked in the exported .AC file. There was object with correct name with 2 vertexes. I have stupid ask - how can I draw line in the Blender ??? I made plane, then deleted unnecessary edges and obtained line. I'm not sure with that solution...
Fly high, fly fast - fly Concorde !
User avatar
V12
 
Posts: 1289
Joined: Thu Jan 12, 2017 4:27 pm
Location: LZIB
Callsign: BAWV12

Re: Animation of the objects

Postby Necolatis » Wed Sep 20, 2017 4:04 am

For example Add-Curve-Path.
"Airplane travel is nature's way of making you look like your passport photo."
— Al Gore


Hangar: https://sites.google.com/site/fghangar/
User avatar
Necolatis
 
Posts: 1907
Joined: Mon Oct 29, 2012 12:40 am
Location: EKOD
Callsign: Leto
IRC name: Neco
Version: 2018.3.2
OS: Windows 10


Return to Aircraft

Who is online

Users browsing this forum: AhrefsBot [Bot] and 3 guests