Lumiera 0.pre.04
»edit your freedom«
Loading...
Searching...
No Matches
pipe.cpp
Go to the documentation of this file.
1/*
2 Pipe - structural asset denoting a processing pipe to generate media output
3
4 Copyright (C)
5 2008, Hermann Vosseler <Ichthyostega@web.de>
6
7  **Lumiera** is free software; you can redistribute it and/or modify it
8  under the terms of the GNU General Public License as published by the
9  Free Software Foundation; either version 2 of the License, or (at your
10  option) any later version. See the file COPYING for further details.
11
12* *****************************************************************/
13
14
20#include "steam/asset/pipe.hpp"
22#include "lib/util.hpp"
23
24using util::isnil;
25
26namespace steam {
27namespace asset {
28
29
38 , string const& streamID
39 , PProcPatt& wiring
40 , string shortName
41 , string longName
42 )
43 : Struct (idi)
44 , wiringTemplate_(wiring)
45 , streamID_(streamID)
46 , shortDesc (shortName)
47 , longDesc (longName)
48 {
49 REQUIRE (idi.isValid());
50 if (isnil (shortDesc))
51 shortDesc = string(idi);
52 }
53
54
55
56 PPipe
57 Pipe::query (string const& properties)
58 {
59 return Struct::retrieve (Query<Pipe> (properties));
60 }
61
62
66 PPipe
68 {
69 return AssetManager::instance().getAsset(id);
70 }
71
72
73 void
75 {
76 wiringTemplate_ = another;
77 TODO ("trigger rebuild fixture");
78 }
79
80
81
82
83}} // namespace asset
Steam-Layer Interface: Asset Lookup and Organisation.
Generic interface to express a query for specifically typed result elements exposing some capabilitie...
Definition query.hpp:254
static lib::Depend< AssetManager > instance
get at the system-wide asset manager instance.
thin wrapper around a size_t hash ID used as primary key for all Asset objects.
Definition asset.hpp:98
Pipe(Asset::Ident const &, string const &streamID, PProcPatt &wiring, string shortName="", string longName="")
Create and register a new Pipe asset.
Definition pipe.cpp:37
static PPipe query(string const &properties)
convenience shortcut for retrieving default configured pipes
Definition pipe.cpp:57
void switchProcPatt(PProcPatt &another)
use another wiring template.
Definition pipe.cpp:74
PProcPatt wiringTemplate_
Definition pipe.hpp:73
string shortDesc
Definition pipe.hpp:77
static PPipe lookup(ID< Pipe > id)
convenience shortcut for lookup by id
Definition pipe.cpp:67
key abstraction: structural asset Created automatically as a sideeffect of building the structure of ...
Definition struct.hpp:105
static StructFactory retrieve
storage for the static StructFactory instance
Definition struct.hpp:107
The asset subsystem of the Steam-Layer.
Steam-Layer implementation namespace root.
bool isnil(lib::time::Duration const &dur)
A "processing pipe" represented as Asset.
a POD comprised of all the information sufficiently identifying any given Asset.
Definition asset.hpp:147
Tiny helper functions and shortcuts to be used everywhere Consider this header to be effectively incl...