2007-09-02 18:48:22 +02:00
|
|
|
/*
|
2008-02-14 04:12:30 +01:00
|
|
|
Pipe - structural asset denoting a processing pipe generating media output
|
2007-09-02 18:48:22 +02:00
|
|
|
|
2008-03-10 04:25:03 +01:00
|
|
|
Copyright (C) Lumiera.org
|
|
|
|
|
2008, Hermann Vosseler <Ichthyostega@web.de>
|
2007-09-02 18:48:22 +02:00
|
|
|
|
|
|
|
|
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.
|
|
|
|
|
|
|
|
|
|
* *****************************************************/
|
|
|
|
|
|
|
|
|
|
|
2008-02-14 04:12:30 +01:00
|
|
|
#include "proc/asset/pipe.hpp"
|
2008-12-17 17:53:32 +01:00
|
|
|
#include "lib/util.hpp"
|
2008-02-18 04:16:53 +01:00
|
|
|
|
|
|
|
|
using util::isnil;
|
2007-09-02 18:48:22 +02:00
|
|
|
|
|
|
|
|
namespace asset
|
|
|
|
|
{
|
2008-01-12 18:19:37 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
/** */
|
2008-02-18 04:16:53 +01:00
|
|
|
Pipe::Pipe ( const Asset::Ident& idi
|
|
|
|
|
, PProcPatt& wiring
|
|
|
|
|
, const string& pipeID
|
|
|
|
|
, wstring shortName
|
|
|
|
|
, wstring longName
|
|
|
|
|
)
|
|
|
|
|
: Struct (idi),
|
2008-02-14 04:12:30 +01:00
|
|
|
pipeID_ (pipeID),
|
2008-02-13 04:41:58 +01:00
|
|
|
wiringTemplate(wiring),
|
2008-02-18 04:16:53 +01:00
|
|
|
shortDesc (shortName),
|
|
|
|
|
longDesc (longName)
|
2008-01-12 18:19:37 +01:00
|
|
|
{
|
2008-02-18 04:16:53 +01:00
|
|
|
REQUIRE (!isnil (pipeID));
|
|
|
|
|
if (isnil (shortDesc))
|
|
|
|
|
shortDesc = wstring (pipeID.begin(), pipeID.end());
|
2008-01-12 18:19:37 +01:00
|
|
|
}
|
|
|
|
|
|
2008-01-14 01:01:11 +01:00
|
|
|
|
|
|
|
|
|
2008-02-14 04:12:30 +01:00
|
|
|
PPipe
|
|
|
|
|
Pipe::query (string properties)
|
2008-01-27 23:40:45 +01:00
|
|
|
{
|
2008-02-14 04:12:30 +01:00
|
|
|
return Struct::create (Query<Pipe> (properties));
|
2008-01-27 23:40:45 +01:00
|
|
|
}
|
|
|
|
|
|
2008-01-14 01:01:11 +01:00
|
|
|
void
|
2008-02-14 04:12:30 +01:00
|
|
|
Pipe::switchProcPatt (PProcPatt& another)
|
2008-01-14 01:01:11 +01:00
|
|
|
{
|
|
|
|
|
wiringTemplate = another;
|
|
|
|
|
TODO ("trigger rebuild fixture");
|
|
|
|
|
}
|
|
|
|
|
|
2007-09-02 18:48:22 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} // namespace asset
|