Uses ffmpeg libraries to provide video encoding of an osg::GraphicsContext
(which could be for Flightgear's main window) to file.
The video codec is specified as a string at runtime. Success depends on what is
supported by the system's ffmpeg installation.
Handling of resize doesn't always work. We finish current stream and create a
new encoder and continue. Works ok with mpeg2, but with more modern codecs vlc
usually fails to handle the change.
We call the encoder on a separate thread to avoid latency.
If SG_FFMPEG is not defined, we don't make calls to ffmpeg libraries and
VideoEncoder class's constructor always throws an exception.
- Prefix all WS30 Uniforms with "fg_"
- fix modelOffset (needs to be passed in as a float)
- Create a true atlas with indexes for relevant material textures
MCST E2K (Elbrus 2000) - this is VLIW/EPIC architecture, like Intel Itanium (IA-64) architecture.
e2k architecture has half native / half software support of most Intel/AMD SIMD
e.g. MMX/SSE/SSE2/SSE3/SSSE3/SSE4.1/SSE4.2/AES/AVX/AVX2 & 3DNow!/SSE4a/XOP/FMA4
Ref: https://en.wikipedia.org/wiki/Elbrus_2000
To simplify various rounding / truncation operations, especially when
dealing with frequency values, give floor() the same precision control
already present in math.round(), and add math.trunc() which always
truncates towards zero.
Earlier calculations assumed degrees instead of radians for the
granularity of random lights, resulting to the wrong density. This
is now fixed. The scanline for random lights is also more efficient
now, taking the lower limit of light-coverage into account.
Previously we were taking the nearest pixel from the nearest
mipmap. Which was braindead. Now just use the OSG defaults,
which are NEAREST_MIPMAP_LINEAR for MIN and LINEAR for MAX.
Thanks to Julian and Henning for helping diagnose this on
the weekly hangout.
Previously VPB tiles were loaded by the STG file handler.
Now they are loaded directly by the tile manager, allowing
better management of tile loading.
This will allow an object to be moved using a line (with 2d points).
Use the factor to switch direction (direction will depend on the order of definition of the end points of the vertex and) together with a (usually normalised property to define how much of the translation to apply).
<animation>
<type>translate</type>
<object-name>mm_radios-display</object-name>
<property>/sim/model/f-14/radio-position-norm</property>
<factor>-1</factor>
<axis>
<object-name>mm_radios-display-alt-position-axis</object-name>
</axis>
</animation>
On VR with visibility masking the depth buffer is first set to the
nearest possible value in parts of the frame that won't be visible
through the VR headset's lenses. This is meant to reduce GPU fragment
load.
The sky dome however is rendered with depth testing disabled which
bypasses the visibility masking. To allow invisible parts of the sky
dome to be culled, enable depth testing but set the depth mask to false
to prevent modification of the depth buffer.
Previously the STG Loader had a class member keeping track
of each WS30 tile that had been loaded, to ensure the terrain
was only loaded once.
However, this was a class member on a loader, and we have multiple
OSG loading threads. So the WS30 terrain was loaded ~6 times.
Change to a static, protected with a mutex so we only load the tile
once.
50% improvement in fps from the reduction in vertices, and an
improvement in loading.
simgear/scene/model/animation.*: added TransformExpression() - returns SGExpressiond
if given a SGRotAnimTransform or SGTranslateTransform.
simgear/scene/model/SGTranslateTransform.hxx:SGTranslateTransform: added copy
of SGExpressiond for use by TransformExpression().
Add LEFT_BIT and RIGHT_BIT node masks, which are only shown on the left
or right viewports. These will be used for eye specific visibility masks
with VR.
To allow for custom compositors and passes created by C++ code alongside
those created by Compositor::create(), add a resetOrderOffset() function
which resets _order_offset back to zero. This will allow FlightGear to
prevent repeated compositor reloads from increasing _order_offset
indefinitely, which soon results in render orders beyond those set
statically for the GUI and upcoming VR mirror compositors.
The Canvas camera and texture get recreated in several circumstances.
Calling .release() on a ref_ptr will just return the raw pointer and
'delete' won't be called. The proper way to explicitly delete an object
managed by a ref_ptr is to set the ref_ptr to NULL. This will delete it
as long as it's not referenced by any other ref_ptr.