DoorKeeper/include/implem/layer.inl
King_DuckZ 9086de8dae Advancing with the implementation.
The iterator is not included anywhere yet so it's completely untested.
Next step is to define the relationship between views and layers, so iterators can be put
into the class that will be responsible to spawn them.
2014-12-11 23:58:52 +01:00

21 lines
903 B
C++

namespace dk {
///--------------------------------------------------------------------------
///--------------------------------------------------------------------------
template <size_t D>
LayerBase<D>::LayerBase (const coords& parSize, const coords& parTileSize, const coords& parMasterTileSize) :
m_size(parSize),
m_tilesize(parTileSize),
m_mastersize(parMasterTileSize)
{
DK_ASSERT((parMasterTileSize / parTileSize) * parTileSize == parMasterTileSize);
}
///--------------------------------------------------------------------------
///--------------------------------------------------------------------------
template <typename T, size_t D>
Layer<T, D>::Layer (const coords& parSize, const coords& parTileSize, const coords& parMasterTileSize, streamer_type&& parStreamer) :
LayerBase<D>(parSize, parTileSize, parMasterTileSize),
m_streamer(std::move(parStreamer))
{
}
}