public static GRContext Create (GRBackend backend, GRGlInterface backendContext, GRContextOptions options) { if (backendContext == null) { throw new ArgumentNullException (nameof (backendContext)); } return GetObject<GRContext> (SkiaApi.gr_context_create (backend, backendContext.Handle, ref options)); }
public static GRContext Create(GRBackend backend, GRGlInterface backendContext, GRContextOptions options) { if (backendContext == null) { throw new ArgumentNullException(nameof(backendContext)); } return(GetObject <GRContext> (SkiaApi.gr_context_create(backend, backendContext.Handle, ref options))); }
public static GRContext Create(GRBackend backend, IntPtr backendContext) { switch (backend) { case GRBackend.Metal: throw new NotSupportedException(); case GRBackend.OpenGL: return(GetObject <GRContext> (SkiaApi.gr_context_make_gl(backendContext))); case GRBackend.Vulkan: throw new NotSupportedException(); default: throw new ArgumentOutOfRangeException(nameof(backend)); } }
public static GRContext Create(GRBackend backend, GRGlInterface backendContext) { switch (backend) { case GRBackend.Metal: throw new NotSupportedException(); case GRBackend.OpenGL: return(CreateGl(backendContext)); case GRBackend.Vulkan: throw new NotSupportedException(); default: throw new ArgumentOutOfRangeException(nameof(backend)); } }
public GRBackendRenderTarget(GRBackend backend, GRBackendRenderTargetDesc desc) : this(IntPtr.Zero, true) { switch (backend) { case GRBackend.Metal: throw new NotSupportedException(); case GRBackend.OpenGL: var glInfo = new GRGlFramebufferInfo((uint)desc.RenderTargetHandle, desc.Config.ToGlSizedFormat()); CreateGl(desc.Width, desc.Height, desc.SampleCount, desc.StencilBits, glInfo); break; case GRBackend.Vulkan: throw new NotSupportedException(); default: throw new ArgumentOutOfRangeException(nameof(backend)); } }
public static GRContext Create(GRBackend backend, IntPtr backendContext, GRContextOptions options) { return(GetObject <GRContext> (SkiaApi.gr_context_create(backend, backendContext, ref options))); }
public static GRContext Create(GRBackend backend, IntPtr backendContext) { return(GetObject <GRContext> (SkiaApi.gr_context_create_with_defaults(backend, backendContext))); }
public static GRContext Create(GRBackend backend) { return(Create(backend, IntPtr.Zero)); }
public static GRContext Create(GRBackend backend, GRGlInterface backendContext, GRContextOptions options) { return(GetObject <GRContext> (SkiaApi.gr_context_create(backend, backendContext.Handle, ref options))); }
public static GRContext Create (GRBackend backend, IntPtr backendContext, GRContextOptions options) { return GetObject<GRContext> (SkiaApi.gr_context_create (backend, backendContext, ref options)); }
public static GRContext Create (GRBackend backend, IntPtr backendContext) { return GetObject<GRContext> (SkiaApi.gr_context_create_with_defaults (backend, backendContext)); }
public static GRContext Create (GRBackend backend) { return Create (backend, IntPtr.Zero); }
public extern static gr_context_t gr_context_create_with_defaults (GRBackend backend, GRBackendContext backendContext);
public extern static gr_context_t gr_context_create (GRBackend backend, GRBackendContext backendContext, ref GRContextOptions options);
internal static GRBackendNative ToNative(this GRBackend backend) => backend switch {
public static GRContext Create(GRBackend backend) => backend switch {
public static GRContext Create(GRBackend backend, GRGlInterface backendContext) { return(GetObject <GRContext> (SkiaApi.gr_context_create_with_defaults(backend, backendContext.Handle))); }