WIP start drafting how to bootstrap a stream type...

This commit is contained in:
Fischlurch 2008-09-17 03:46:38 +02:00
parent 8754555492
commit a6a19ef609
6 changed files with 142 additions and 5 deletions

View file

@ -28,7 +28,9 @@ namespace lumiera
{
/** */
int bla = 3;
StreamType::ImplFacade::~ImplFacade()
{ }
} // namespace lumiera

View file

@ -40,8 +40,7 @@
#include <boost/noncopyable.hpp>
namespace lumiera
{
namespace lumiera {
/**
@ -116,6 +115,7 @@ namespace lumiera
virtual DataBuffer* createFrame () const;
virtual ~ImplFacade() ;
};

View file

@ -280,6 +280,10 @@ out: dtor ~TargetObj(24) successfull
END
PLANNED "StreamTypeBasics_test" StreamTypeBasics_test <<END
END
TEST "TestOption_test" TestOption_test <<END
out: Testing invocation with cmdline: ...
out: --> Testgroup=ALL

View file

@ -0,0 +1,67 @@
/*
StreamTypeBasics(Test) - check the fundamentals of stream type information
Copyright (C) Lumiera.org
2008, Hermann Vosseler <Ichthyostega@web.de>
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation; either version 2 of the
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
* *****************************************************/
#include "common/test/run.hpp"
#include "common/util.hpp"
#include "teststreamtypes.hpp"
#include <iostream>
using std::cout;
namespace lumiera {
namespace test {
/*******************************************************************
* @test check the basic workings of the stream type handling.
* create some stream implementation data, build a
* StreamType::ImplFacade from this, and derive a prototype
* and a full StreamType based on this information.
*/
class StreamTypeBasics_test : public Test
{
virtual void run (Arg arg)
{
buildImplType ();
}
void buildImplType ()
{
StreamType::ImplFacade iType = createImplType ();
UNIMPLEMENTED ("get a lib descriptor");
UNIMPLEMENTED ("check the lib of the type");
UNIMPLEMENTED ("compare two types");
}
};
LAUNCHER (StreamTypeBasics_test, "unit common");
} // namespace test
} // namespace lumiera

View file

@ -0,0 +1,52 @@
/*
TESTSTREAMTYPES.hpp - create test (stub) stream type information
Copyright (C) Lumiera.org
2008, Hermann Vosseler <Ichthyostega@web.de>
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation; either version 2 of the
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
#ifndef LUMIERA_TEST_TESTSTREAMTYPES_H
#define LUMIERA_TEST_TESTSTREAMTYPES_H
//#include "common/util.hpp"
#include "common/streamtype.hpp"
#include "proc/control/stypemanager.hpp"
namespace lumiera {
namespace test {
/** Helper: create an implementation frame
* and build the corresponding streamtype
*/
inline StreamType::ImplFacade
createImplType ()
{
UNIMPLEMENTED ("create a test stream type from a given GAVL type tag");
}
} // namespace test
} // namespace lumiera
#endif

View file

@ -3382,7 +3382,7 @@ Within the Proc-Layer, media streams are treated largely in a similar manner. Bu
&amp;rarr; see also &amp;raquo;[[Stream Type|StreamType]]&amp;laquo;
</pre>
</div>
<div title="StreamTypeUse" modifier="Ichthyostega" modified="200809150339" created="200809130312" tags="draft discuss dynamic" changecount="11">
<div title="StreamTypeUse" modifier="Ichthyostega" modified="200809170107" created="200809130312" tags="draft discuss dynamic" changecount="13">
<pre>Questions regarding the use of StreamType within the Proc-Layer.
* what is the relation between Buffer and Frame?
@ -3409,10 +3409,22 @@ Thus, //constraints may be viewed as type constructing functors.//
--------------
!use cases
* pulling from a media file
* pulling data from a media file
* connecting pipes and similar wiring problems
* describing the properties of an processor plugin
!! pulling data from a media file
To open the file, we need //type discovery code,// resulting in a handle to some library module for accessing the contents, which is in compliance with the Lumiera application. Thus, we can determine the possible return values of this type discovery code and provide code which wires up a corresponding StreamTypeImpleFacade. Further, the {{{control::STypeManager}}} has the ability to build a complete or partial StreamType from
* an ~ImplFacade
* a Prototype
* maybe even from some generic textual IDs?
!! wiring problems
When deciding if a connection can be made, we can build up the type information starting out from the source. (this requires some work, but it's //possible,// generally speaking.). Thus, we can allways get an ~ImplType for the &quot;lower end&quot; of the connection, and at least a Prototype for the &quot;output side&quot; &amp;mdash; which should be enough to use the query functions provided by the stream type interfaces
!! describing properties
{{red{currently difficult to define}}} as of 9/2008, because the property description of plugins is not planned yet.
My Idea was to use [[type implementation constraints|StreanTyoeImplConstraint]] for this, which are a special kind of ~ImplType
</pre>
</div>
<div title="StrongSeparation" modifier="MichaelPloujnikov" modified="200706271504" created="200706220452" tags="design" changecount="5">