PageRenderTime 21ms CodeModel.GetById 14ms app.highlight 3ms RepoModel.GetById 1ms app.codeStats 1ms

/Source Code/ExperimentalProjection/ProjectorFactory.vb

#
Visual Basic | 28 lines | 10 code | 5 blank | 13 comment | 0 complexity | 13d48476b6b8d827a28e09893ad98bf3 MD5 | raw file
 1''' <summary>
 2''' Contains methods for instantiating projectors.
 3''' </summary>
 4Public NotInheritable Class ProjectorFactory
 5
 6    Private Sub New()
 7
 8    End Sub
 9
10    ''' <summary>
11    ''' Creates a new instance of a GDI projector.
12    ''' </summary>
13    ''' <param name="surfaceControl">The surface control to use in rendering the projection.</param>
14    ''' <returns>A new instance of a GDI projector.</returns>
15    Public Shared Function CreateGdiProjector(ByVal surfaceControl As Control) As GdiProjector
16        Return New GdiProjector(surfaceControl)
17    End Function
18
19    ''' <summary>
20    ''' Creates a new instance of a WPF projector.
21    ''' </summary>
22    ''' <param name="surfaceControl">The surface control to use in rendering the projection.</param>
23    ''' <returns>A new instance of a WPF projector.</returns>
24    Public Shared Function CreateWpfProjector(ByVal surfaceControl As System.Windows.Controls.Grid) As WpfProjector
25        Return New WpfProjector(surfaceControl)
26    End Function
27
28End Class