Thomas Geymayer
d3a14bfd61
canvas: BoxLayout shared pointer typedef.
2014-06-04 17:48:46 +02:00
Thomas Geymayer
03cafe4547
Catalog: add method to get all packages in a catalog.
2014-06-04 17:47:29 +02:00
Thomas Geymayer
e5acc3f048
cppbind::Ghost: improve compiler error message for wrong usage.
2014-06-04 17:46:35 +02:00
Thomas Geymayer
4931ce0364
This has to work on windows now^^
2014-06-04 13:41:48 +02:00
Thomas Geymayer
e3d53e854a
Hopefully fixing windows build.
2014-06-04 12:17:00 +02:00
Thomas Geymayer
bdf6b25338
Now the real fix for old compilers...
2014-06-04 03:16:02 +02:00
Thomas Geymayer
5dddba26ac
Fix headless build and reduce include dependencies.
2014-06-04 02:46:57 +02:00
Thomas Geymayer
746fa419ed
Trying to fix problems retrieving static member address with old compilers.
2014-06-04 02:45:52 +02:00
Thomas Geymayer
7080f919e9
Fix for old versions of Boost.
...
No support for BOOST_STATIC_ASSERT_MSG before Boost 1.46.
2014-06-03 20:34:21 +02:00
Thomas Geymayer
c4e0014d74
cppbind::Ghost: safely use strong and weak references.
...
Allow using strong and weak references within the same
class hierarchy and seemlessly convert between them -
from and to Nasal.
2014-06-03 18:40:01 +02:00
Thomas Geymayer
7d9797e091
SGSharedPtr: add constructor to convert from SGWeakPtr.
2014-06-03 01:58:57 +02:00
Thomas Geymayer
32274027ef
Missing return statement
2014-06-01 12:14:31 +02:00
Thomas Geymayer
d09943cbb8
Fix wrong include guard (identified by clang)
2014-06-01 12:12:28 +02:00
Thomas Geymayer
150039f9ba
Canvas/Layout: tweak the way elements are exposed to Nasal.
2014-06-01 12:12:28 +02:00
Thomas Geymayer
820a315cbe
Canvas: fix possible crash with destroyed canvasses
2014-06-01 12:12:28 +02:00
Thomas Geymayer
8abe4622b9
Canvas: trigger immediate update from property tree/Nasal.
2014-06-01 12:12:28 +02:00
Thomas Geymayer
b36cdebe8b
Canvas: basic layouting system.
...
Support for vertical and horizontal layouts. More layouts and
widgets can be created using Nasal.
2014-05-31 02:40:59 +02:00
Thomas Geymayer
3c0544c9a6
Sky dome: remove unused variables/code.
2014-05-31 00:09:56 +02:00
Thomas Geymayer
be358f8d24
cppbind: use Hash iterators to extract simgear::Map
2014-05-30 23:59:36 +02:00
Thomas Geymayer
e1abab393b
Fix for clang/template dependent name lookup.
...
Thanks to James & Nicholas...
2014-05-30 23:57:55 +02:00
Thomas Geymayer
0b21181f1a
Canvas: allow dispatching events to Canavs itself
2014-05-29 16:34:33 +02:00
Thomas Geymayer
dfdd1c6d5e
cppbind: some new methods and safer type check.
2014-05-29 16:30:41 +02:00
Thomas Geymayer
a8e96997cb
nasal::Hash: add iterators.
2014-05-29 14:14:52 +02:00
Thomas Geymayer
6db07373ee
PropertyBasedElement: extend HTML5 (Canvas) data props interface
...
Allow check if property exists and removing properties.
2014-05-29 01:22:35 +02:00
Thomas Geymayer
36ae8cdce3
Update doxgen config and some comments.
2014-05-29 00:27:50 +02:00
Thomas Geymayer
d77ba7d2db
canvas::Element: setter/getter for HTML5 style data-* properties.
2014-05-28 18:11:32 +02:00
Thomas Geymayer
6e58fdac85
canvas: exclude data-* properties from triggering an update.
...
Allows using data-* properties on canvas and elements,
similar to HTML5, without triggering a new rendering of
the canvas.
2014-05-27 17:56:46 +02:00
Thomas Geymayer
3f6933940e
ShivaVG: get rid of glu dependency.
...
We do not use the image rendering part anyhow, so
just disable it for now. If we want to use it we
will need a modified implementation anyhow to
integrate with OpenSceneGraph threaded OpenGL
resource management.
2014-05-27 17:56:46 +02:00
Thomas Geymayer
9c421d55a9
Canvas: support for custom events and event dispatching.
2014-05-19 00:17:23 +02:00
Thomas Geymayer
1af6cbc1aa
cppbind.Ghost: more member overloads.
2014-05-18 23:55:43 +02:00
Thomas Geymayer
a9e7af6e6e
Enable dynamic linking on Mac for Boost.Test
2014-05-18 17:47:03 +02:00
Thomas Geymayer
c967fbc0a6
cppbind.Ghost: clean up a bit
2014-05-18 17:43:30 +02:00
Thomas Geymayer
6929ba75c0
cppbind: convert maps from nasal.
2014-05-18 13:34:06 +02:00
Thomas Geymayer
289777bd99
cppbind.Ghost: register _get called on retrieving unset member.
...
Allow registering a callback on ghosts called upon retrieving
an unset member.
2014-05-18 13:34:06 +02:00
Thomas Geymayer
7535dfd2d0
cppbind: from_nasal/to_nasal for SGWeakReferenced based objects
2014-05-10 10:49:11 +02:00
Thomas Geymayer
23279b4d0a
Canvas: move window from flightgear.
2014-05-09 16:17:40 +02:00
Thomas Geymayer
d34d3ecfb1
SGWeakReferenced: fix for clang.
2014-05-09 11:52:42 +02:00
Thomas Geymayer
55f18574aa
Fix for CMake 2.6
...
No named arguments for add_test in CMake 2.6.
2014-05-08 11:17:28 +02:00
Thomas Geymayer
02ac1a43c1
Add smart pointer tests (finally using Boost.Test)
2014-05-08 02:17:24 +02:00
Thomas Geymayer
b2c3a90adf
Fix use count for deleted, reference counted objects.
...
Remove inconsitency of returning 0 or ~0. If the object
has been deleted there are no more references, so always
return 0.
2014-05-08 01:43:41 +02:00
Thomas Geymayer
9975c751a7
Add support for using SGWeakPtr with virtual base classes.
...
- Add SGVirtualWeakReferenced to be used as base class
for reference counted objects supporting weak references
and virtual base classes.
- Modify SGWeakPtr to copy with SGVirtualWeakReferenced
objects.
2014-05-08 00:27:00 +02:00
Thomas Geymayer
efbec8b367
Canvas: base Elements/Canvas on SGWeakReferenced.
2014-05-06 18:10:42 +02:00
Thomas Geymayer
9642f6d946
cppbind: add naContext/naRef overload to Ghost::_set
2014-05-06 18:10:35 +02:00
Thomas Geymayer
247aa49849
SGSharedPtr/SGWeakPtr: add some methods/operators
...
- allow placing SGWeakPtr in sorted STL containers (eg. requiring
operator<)
- add reset() like for boost::shared_ptr/boost::weak_ptr
- add helper to extract pointer from SGWeakPtr
2014-05-06 18:10:14 +02:00
Thomas Geymayer
edaae885ee
cppbind: small logging/warning updates.
2014-05-05 15:06:15 +02:00
Thomas Geymayer
b101f64cd8
cppbind.Ghost: register _set called on setting new properties.
2014-05-05 15:06:09 +02:00
Thomas Geymayer
f75d1cbcb1
cppbind: disable special handling of 'parents' for ghost.
2014-05-05 14:48:29 +02:00
Thomas Geymayer
ac2e80dc07
Nasal: allow ghost as 'me' for 'call'
2014-05-05 14:47:10 +02:00
Thomas Geymayer
77955e5c3c
math/nasal: Add more SGRect members and nasal helper.
2014-04-15 10:07:01 +02:00
Thomas Geymayer
338a748823
Canvas::Path: also restore glBlendFunc.
2014-04-01 12:35:43 +02:00
Thomas Geymayer
8c45796dc8
Canvas::Path: reduce number of OpenGL state changes.
...
- Do not enable any multisampling as for FBOs it is not
supported anyhow.
- Just restore GL_BLEND and GL_STENCIL_TEST manually
=> Getting rid of the huge load of glPushAttrib/glPopAttrib
gets us a huge performance boost, especially for drivers
with slow state stack implementations.
2014-04-01 12:03:53 +02:00
Thomas Geymayer
a160e176da
cppbind: fix testing for naRef identity.
2014-03-31 14:21:21 +02:00
Thomas Geymayer
d332da0605
Canvas: do not write bounding box to property tree.
...
- Prevent writing to property tree in wrong thread.
- Add Element::getBoundingBox and
Element::getTightBoundingBox as uniform way to
retrieve bounding boxes of all canvas elements.
- Update path bounding boxe in update traversal.
2014-03-31 13:28:03 +02:00
Thomas Geymayer
6ea55c6851
nasal::Ghost: remove bogus warning.
2014-03-27 12:09:05 +01:00
Thomas Geymayer
10ee7a901f
ShivaVG: disable paint textures ( Fixes #1414 )
...
Currently there is no need for paint textures so just
disable them to prevent releasing OpenGL resources
from the wrong context/thread.
2014-03-27 11:20:38 +01:00
Thomas Geymayer
db8b60ec49
Revert "CanvasGroup: return empty bounding box without children."
...
Returning somehow valid data in case it is used unchecked was
probably not a good idea. Better fix the code using it^^
This fixes #1421 .
This reverts commit 3525fff8d0 .
2014-03-23 17:27:30 +01:00
Thomas Geymayer
09d47e7f55
cppbind: fix problem with function call without arguments.
2014-03-22 13:23:21 +01:00
Thomas Geymayer
13a3ea3503
cppbind: allow calling methods with 'me' object from C++.
2014-03-22 12:41:47 +01:00
Thomas Geymayer
ff53792e4f
CanvasImage: rename 'file' to 'src'.
2014-03-20 11:42:02 +01:00
Thomas Geymayer
fd51518d92
CanvasImage: improve fetching from http and add mime detection.
2014-03-20 01:44:31 +01:00
Thomas Geymayer
01a43b49a5
Canvas: Respect clipping while event handling.
2014-03-19 18:21:25 +01:00
Thomas Geymayer
3525fff8d0
CanvasGroup: return empty bounding box without children.
...
Return an invalid bounding box can lead to problems
if used unchecked. Just returning an empty bounding
box (size 0x0 and position at the origin of the
element) is much safer.
2014-03-19 16:31:17 +01:00
Thomas Geymayer
6c75e2fe3c
CanvasImage: support for http protocol.
...
- Download and display images.
2014-03-18 18:33:44 +01:00
Thomas Geymayer
f28e3fc9bb
Canvas: fix position for drag events and multiclick handling.
...
- Calculate local/client position for every drag event
instead of just reporting the position of the initial
mousedown event.
- Only pressing the same button multiple times increases
the mouse clickcount.
2014-03-15 14:53:08 +01:00
Thomas Geymayer
80e77b8372
Canvas: set button for drag events.
2014-03-15 00:40:48 +01:00
Thomas Geymayer
c851c449da
cppbind: Do not derive from SGReferenced if there is no need
2014-03-12 17:40:21 +01:00
Thomas Geymayer
b2d9385f46
cppbind: fix possible usage of expired object from Nasal
2014-03-11 15:40:26 +01:00
Thomas Geymayer
5560479665
SGPropertyNode: do not keep list of deleted children.
...
Get rid of the possibilty to keep delted children. This was not
used actively, required unnecessary memory for each property node
and lead to subtile bugs, as creating a node after a node with
the same path has been deleted resulted in getting the old node
back instead of a cleanly initialized one.
2014-03-06 00:39:23 +01:00
Thomas Geymayer
aa27a09801
MouseEvent: comply with DOM Level 3 and add some getter.
2014-03-04 17:58:37 +01:00
Thomas Geymayer
91b92c5613
animation: fix for 'textrapezoid' animation outside 'texmultiple'.
2014-02-26 17:48:11 +01:00
Thomas Geymayer
b2cedc5332
Canvas: Fix crash on hide/show after detaching element from scenegraph.
2014-02-22 01:51:54 +01:00
Thomas Geymayer
6b9ce935cd
Write back additional attributes to PropertyList
2014-02-13 18:27:34 +01:00
Thomas Geymayer
781682f4ee
Minor formatting...
2014-02-08 19:15:46 +01:00
Thomas Geymayer
4a10806352
SubsystemMgr: helper to remove all subsystems.
2014-02-08 19:15:14 +01:00
Thomas Geymayer
13ae2f08ee
Put unused attributes in the property tree while parsing.
...
Store unhandled xml attributes in a subnode named _attr_ for each
node on parsing propertylist files. This allows retrieving them at
a later stage where there is no access to the source xml file any
more.
2014-02-08 19:12:17 +01:00
Thomas Geymayer
3e8aeccc87
New textrapezoid TexTransformAnimation.
...
Allows trapezoid texture transformations, as needed for example to
correct for the tilt angle of HUD combiners.
2014-02-08 12:39:43 +01:00
Thomas Geymayer
de39e0093a
Canvas: Fix bounding box calculation for paths with subpaths.
2014-02-08 00:22:36 +01:00
Thomas Geymayer
943f52aedf
Canvas::Element: expose combined transformation matrix
2014-02-06 17:55:51 +01:00
Thomas Geymayer
c54b1e037a
SGPath: typo...
2014-01-28 00:42:20 +01:00
Thomas Geymayer
0d19be2196
SGPath: generalize retrieving standard locations (and add more)
2014-01-28 00:32:08 +01:00
Thomas Geymayer
0428adff03
CanvasMap: Expose property screen-range.
...
Only allowing a hardcoded screen range of 200 units
is not very flexible...
2014-01-09 19:36:38 +01:00
Thomas Geymayer
d82c8eb945
Socket: do not crash on writing to broken pipe.
...
Writing to a closed socket on all Unix/Linux systems raises
a SIGPIPE signal which immediately closes the program. Disabling
raising of SIGPIPE allows proper error handling by checking the
return values of send/sendto and getting the EPIPE in errno.
2014-01-06 12:17:59 +01:00
Thomas Geymayer
2335796a28
Fix track-to animation basic tracking without slave object
2014-01-05 19:38:03 +01:00
Thomas Geymayer
aea71cf0af
HTTPFileRequest: only save file if status == 200
2013-12-30 01:31:47 +01:00
Thomas Geymayer
8dccbe8029
SGPath: some tweaks/fixes/typo on permission checker.
2013-12-12 21:27:27 +01:00
Thomas Geymayer
031c833e4d
SGPath: add support for custom PermissionChecker
...
Allow to add permission checks (read/write-access) for
eg. limiting access based on IORules.
2013-12-12 21:04:26 +01:00
Thomas Geymayer
7a220921f0
Canvas: one global SystemAdapter is enough.
...
This also fixes elements requiring a SystemAdapter without
being assigned to a Canvas (eg. because they are desktop
elements).
2013-12-09 23:07:17 +01:00
Thomas Geymayer
7ef9acda5d
Add ListDiff helper (for fast array differences).
2013-12-08 18:48:57 +01:00
Thomas Geymayer
2a6d62e6f7
Fix some unused/uninitialized variables.
2013-12-07 13:43:17 +01:00
Thomas Geymayer
42b50bd7f7
SGPropertyNode: add removeAllChildren() method
2013-12-07 13:42:15 +01:00
Thomas Geymayer
2c3f44ae11
Canvas: ensure all canvasses are destroyed
...
- For shutdown/reset make sure all properties describing a canvas
are removed and also not restored after the reset.
2013-12-07 13:40:22 +01:00
Thomas Geymayer
7c5434a99f
cppbind: don't leak nasal references for Ghost methods.
2013-12-04 11:15:11 +01:00
Thomas Geymayer
66193d7283
cppbind: Fix detecting derived Ghosts
2013-12-01 12:35:02 +01:00
Thomas Geymayer
dfb07f359e
cppbind: make ghost_type static to keep same pointer on reset.
...
Using a static naGhostType ensures that always the same
address is used for the same ghost and prevents ghost_types
from getting invalid (eg. on reset).
2013-12-01 01:18:13 +01:00
Thomas Geymayer
6fe1433497
Canvas: allow removing placement factories.
2013-11-24 15:39:03 +01:00
Thomas Geymayer
743244a69c
CanvasElement: ensure parent pointer can not become invalid.
2013-11-10 17:12:50 +01:00
Thomas Geymayer
9f89737986
track-to animation: fix "short" and "long" tracking.
2013-11-10 11:14:50 +01:00
Thomas Geymayer
508a5c5f66
track-to animation: 2dof rotation for slave object.
...
Slave objects can now rotate around two axis to always track the
target - even when it is outside the plane perpendicular to the
lock-axis of the root object. This allows for example animating
levers with non-parallel axis of rotation connected with a rod.
2013-11-08 00:51:18 +01:00
Thomas Geymayer
ec4d3e4f9b
Make new gcc happy (include cmath)
2013-11-04 10:48:26 +01:00
Thomas Geymayer
38ddfab1e0
Canvas: improved clipping and new property clip-frame.
...
- Update clipping rect if canvas view or texture size
changes.
- Add new property "clip-frame" to specify coordinate
frame for "clip" coordinates. Coordinates can be
global, relative to the parent or relative to the
element itself.
2013-11-03 20:12:45 +01:00