From 2fd7a2f6f9bfdf5a212c705244af0ae9564209ac Mon Sep 17 00:00:00 2001 From: Ichthyostega Date: Thu, 7 Jan 2010 08:28:54 +0100 Subject: [PATCH] patch temporary re-entrance problems on session creation (maybe #495) --- src/proc/asset/structfactoryimpl.hpp | 2 +- src/proc/mobject/session/edl.hpp | 6 ++++-- src/proc/mobject/session/session-impl.cpp | 11 ++++++----- src/proc/mobject/session/session-impl.hpp | 10 ++++++++-- tests/components/proc/mobject/session/addcliptest.cpp | 5 +++-- .../proc/mobject/session/sessionstructuretest.cpp | 3 +++ wiki/renderengine.html | 4 ++-- 7 files changed, 27 insertions(+), 14 deletions(-) diff --git a/src/proc/asset/structfactoryimpl.hpp b/src/proc/asset/structfactoryimpl.hpp index f39d41b05..a3bce4b60 100644 --- a/src/proc/asset/structfactoryimpl.hpp +++ b/src/proc/asset/structfactoryimpl.hpp @@ -149,7 +149,7 @@ namespace asset StructFactoryImpl::fabricate (const Query& caps) { TODO ("actually extract properties/capabilities from the query..."); - TODO ("make sure AssetManager detects dublicates (currently 4/08 it doesn't)"); + TODO ("make sure AssetManager detects duplicates (currently 4/08 it doesn't)"); return new Track (createIdent (caps)); } diff --git a/src/proc/mobject/session/edl.hpp b/src/proc/mobject/session/edl.hpp index e72b91bad..f6e3db000 100644 --- a/src/proc/mobject/session/edl.hpp +++ b/src/proc/mobject/session/edl.hpp @@ -40,7 +40,9 @@ namespace mobject { namespace session { - class EDL ///////////////////////////TODO is considered to be renamed as "Sequence". Should be converted to an Inteface + class EDL ///////////////////////////TICKET #152 EDL will be renamed to "Sequence". + ///////////////////////////TODO: Should be converted to an facade interface + ///////////////////////////TODO: what follows is dummy code and will be dropped! { protected: Placement track; @@ -55,7 +57,7 @@ namespace mobject { Placement& getTracks () { return track; } ///< @todo work out the correct use of tracks! make const correct! size_t size () { - UNIMPLEMENTED ("what ist the 'size' of an EDL?"); + UNIMPLEMENTED ("what is the 'size' of an EDL?"); return 0; } diff --git a/src/proc/mobject/session/session-impl.cpp b/src/proc/mobject/session/session-impl.cpp index 07298f9ca..1b17e019e 100644 --- a/src/proc/mobject/session/session-impl.cpp +++ b/src/proc/mobject/session/session-impl.cpp @@ -50,12 +50,13 @@ namespace session { * system (and this is desirable) */ SessionImpl::SessionImpl () - : Session( getDummyDefaultsManager() ), ///////TODO temporary hack - focusEDL_(0), - edls(1), - fixture(new Fixture), - pIdx_( MObject::create (getDummyDefaultsManager())) ////TODO temporary hack + : Session( getDummyDefaultsManager() ) ///////TODO temporary hack + , pIdx_( MObject::create (getDummyDefaultsManager())) ////TODO temporary hack + , focusEDL_(0) + , edls() /////////// this is dummy code. How to initialise the default session? ///////TICKET #497 + , fixture(new Fixture) { + INFO (session, "new Session created."); } diff --git a/src/proc/mobject/session/session-impl.hpp b/src/proc/mobject/session/session-impl.hpp index 475ec1a3b..15c49118a 100644 --- a/src/proc/mobject/session/session-impl.hpp +++ b/src/proc/mobject/session/session-impl.hpp @@ -78,11 +78,12 @@ namespace session { */ class SessionImpl : public mobject::Session { + PlacementIndex pIdx_; + uint focusEDL_; - vector edls; + vector edls; /////////////////////TICKET #500 PFix fixture; - PlacementIndex pIdx_; scoped_ptr defaultsManager_; ///////////TODO: later, this will be the real defaults manager. Currently this is just never initialised (11/09) @@ -180,6 +181,11 @@ namespace session { { mockIndex_ = alternativeIndex; } + + protected: + ServiceAccessPoint() + : mockIndex_(0) + { } private: PlacementIndex* mockIndex_; diff --git a/tests/components/proc/mobject/session/addcliptest.cpp b/tests/components/proc/mobject/session/addcliptest.cpp index 7d7469448..e3b9f2b36 100644 --- a/tests/components/proc/mobject/session/addcliptest.cpp +++ b/tests/components/proc/mobject/session/addcliptest.cpp @@ -61,8 +61,9 @@ namespace mobject PSess sess = Session::current; PMO clip = TestClip::create(); sess->add (clip); - - ASSERT (sess->currEDL().contains (clip)); + +///////////////////////////////////////////////////////////////////TICKET #499 +// ASSERT (sess->currEDL().contains (clip)); // TODO: Clip-Asset and Placement magic?? } }; diff --git a/tests/components/proc/mobject/session/sessionstructuretest.cpp b/tests/components/proc/mobject/session/sessionstructuretest.cpp index 198505657..173127dd6 100644 --- a/tests/components/proc/mobject/session/sessionstructuretest.cpp +++ b/tests/components/proc/mobject/session/sessionstructuretest.cpp @@ -59,6 +59,9 @@ namespace mobject run (Arg arg) { PSess sess = Session::current; + + UNIMPLEMENTED("the real standard structure of the session"); //////////////////////////TICKET #499 + ASSERT (0 <= sess->currEDL().size()); // TODO implement ASSERT (0 <= sess->getFixture()->size()); // TODO implement ASSERT (sess->currEDL().getTracks()->isValid()); diff --git a/wiki/renderengine.html b/wiki/renderengine.html index 8898be5b7..af30839c3 100644 --- a/wiki/renderengine.html +++ b/wiki/renderengine.html @@ -4069,11 +4069,11 @@ The HighLevelModel exposes two kinds of interfaces (which are interconnected btw Thus, there is a convenient and meaningful access path through these facade objects, which of course actually is implemented by forwarding to the actual model elements (root, bindings, tracks) -
+
The current [[Session]] is the root of any state found within Proc-Layer. Thus, events defining the session's lifecycle influence and synchronise the cooperative behaviour of the entities within the model, the ProcDispatcher, [[Fixture]] and any facility below.
 * when ''starting'', on first access an empty session is created, which puts any related facility into a defined initial state.
 * when ''closing'' the session, any dependent facilities are disabled, disconnected, halted or closed
-* ''loading'' an existing session &mdash; after closing the previous session &mdash; sets up an empty (default) session an populates it with de-serialised content.
+* ''loading'' an existing session &mdash; after closing the previous session &mdash; sets up an empty (default) session and populates it with de-serialised content.
 * when encountering a ''mutation point'', [[command processing|ProcDispatcher]] is temporarily halted to trigger off an BuildProcess.
 
 !Role of the session manager