WIP
DirectOutput framework for virtual pinball cabinets WIP
Go to:
Overview 
LayerDictionary.cs
Go to the documentation of this file.
1 using System;
2 using System.Collections.Generic;
3 using System.Linq;
4 using System.Text;
6 
7 namespace DirectOutput.Cab.Toys.Layer
8 {
12  public class LayerDictionary<LayerElementType> : SortedDictionary<int, LayerElementType>
13  where LayerElementType : new()
14  {
24  public new LayerElementType this[int LayerNr]
25  {
26  get
27  {
28  try
29  {
30  return base[LayerNr];
31  }
32  catch
33  {
34  LayerElementType L = new LayerElementType();
35  Add(LayerNr, L);
36  return L;
37  }
38  }
39  set
40  {
41  base[LayerNr] = value;
42  }
43  }
44 
45 
46 
47 
48  }
49 }
Dictionary for RGBALayer objects.
The namespace DirectOutput.General contains classes for general use.