/// <summary> /// Application entry point. /// </summary> /// <param name="args"> /// The command line invocation arguments. /// </param> static void Main(string[] args) { RegistryContext ctx; RegistryProcessor glRegistryProcessor; RegistryDocumentation.CreateLog(); // OpenGL if ((args.Length == 0) || (Array.FindIndex(args, delegate(string item) { return(item == "--gl"); }) >= 0)) { ctx = new RegistryContext("Gl", Path.Combine(BasePath, "GLSpecs/gl.xml")); glRegistryProcessor = new RegistryProcessor(ctx.Registry); GenerateCommandsAndEnums(glRegistryProcessor, ctx); GenerateExtensionsSupportClass(glRegistryProcessor, ctx); GenerateVersionsSupportClass(glRegistryProcessor, ctx); } #if false // OpenGL ES if ((args.Length == 0) || (Array.FindIndex(args, delegate(string item) { return(item == "--gles"); }) >= 0)) { ctx = new RegistryContext("Gles", Path.Combine(BasePath, "GLSpecs/gl.xml")); glRegistryProcessor = new RegistryProcessor(ctx.Registry); GenerateCommandsAndEnums(glRegistryProcessor, ctx); } #endif // OpenGL for Windows if ((args.Length == 0) || (Array.FindIndex(args, delegate(string item) { return(item == "--wgl"); }) >= 0)) { ctx = new RegistryContext("Wgl", Path.Combine(BasePath, "GLSpecs/wgl.xml")); glRegistryProcessor = new RegistryProcessor(ctx.Registry); GenerateCommandsAndEnums(glRegistryProcessor, ctx); GenerateExtensionsSupportClass(glRegistryProcessor, ctx); GenerateVersionsSupportClass(glRegistryProcessor, ctx); } // OpenGL for Unix if ((args.Length == 0) || (Array.FindIndex(args, delegate(string item) { return(item == "--xgl"); }) >= 0)) { ctx = new RegistryContext("Glx", Path.Combine(BasePath, "GLSpecs/glx.xml")); glRegistryProcessor = new RegistryProcessor(ctx.Registry); GenerateCommandsAndEnums(glRegistryProcessor, ctx); GenerateExtensionsSupportClass(glRegistryProcessor, ctx); GenerateVersionsSupportClass(glRegistryProcessor, ctx); } // EGL if ((args.Length == 0) || (Array.FindIndex(args, delegate(string item) { return(item == "--egl"); }) >= 0)) { ctx = new RegistryContext("Egl", Path.Combine(BasePath, "GLSpecs/egl.xml")); glRegistryProcessor = new RegistryProcessor(ctx.Registry); GenerateCommandsAndEnums(glRegistryProcessor, ctx); GenerateExtensionsSupportClass(glRegistryProcessor, ctx); GenerateVersionsSupportClass(glRegistryProcessor, ctx); } RegistryDocumentation.CloseLog(); }
/// <summary> /// Application entry point. /// </summary> /// <param name="args"> /// The command line invocation arguments. /// </param> static void Main(string[] args) { RegistryContext ctx; RegistryProcessor glRegistryProcessor; RegistryDocumentation.CreateLog(); // XML-based speicfications // OpenGL if ((args.Length == 0) || (Array.FindIndex(args, delegate(string item) { return(item == "--gl"); }) >= 0)) { ctx = new RegistryContext("Gl", Path.Combine(BasePath, "GLSpecs/gl.xml")); glRegistryProcessor = new RegistryProcessor(ctx.Registry); GenerateCommandsAndEnums(glRegistryProcessor, ctx); GenerateExtensionsSupportClass(glRegistryProcessor, ctx); GenerateVersionsSupportClass(glRegistryProcessor, ctx); GenerateVbCommands(glRegistryProcessor, ctx); } // OpenGL for Windows if ((args.Length == 0) || (Array.FindIndex(args, delegate(string item) { return(item == "--wgl"); }) >= 0)) { ctx = new RegistryContext("Wgl", Path.Combine(BasePath, "GLSpecs/wgl.xml")); glRegistryProcessor = new RegistryProcessor(ctx.Registry); GenerateCommandsAndEnums(glRegistryProcessor, ctx); GenerateExtensionsSupportClass(glRegistryProcessor, ctx); GenerateVersionsSupportClass(glRegistryProcessor, ctx); GenerateVbCommands(glRegistryProcessor, ctx); } // OpenGL for Unix if ((args.Length == 0) || (Array.FindIndex(args, delegate(string item) { return(item == "--glx"); }) >= 0)) { ctx = new RegistryContext("Glx", Path.Combine(BasePath, "GLSpecs/glx.xml")); glRegistryProcessor = new RegistryProcessor(ctx.Registry); GenerateCommandsAndEnums(glRegistryProcessor, ctx); GenerateExtensionsSupportClass(glRegistryProcessor, ctx); GenerateVersionsSupportClass(glRegistryProcessor, ctx); GenerateVbCommands(glRegistryProcessor, ctx); } // EGL if ((args.Length == 0) || (Array.FindIndex(args, delegate(string item) { return(item == "--egl"); }) >= 0)) { ctx = new RegistryContext("Egl", Path.Combine(BasePath, "GLSpecs/egl.xml")); glRegistryProcessor = new RegistryProcessor(ctx.Registry); GenerateCommandsAndEnums(glRegistryProcessor, ctx); GenerateExtensionsSupportClass(glRegistryProcessor, ctx); GenerateVersionsSupportClass(glRegistryProcessor, ctx); GenerateVbCommands(glRegistryProcessor, ctx); } // OpenWF _OutputBasePath = "OpenWF.Net"; _Namespace = "OpenWF"; // OpenWF(C) if ((args.Length == 0) || (Array.FindIndex(args, delegate(string item) { return(item == "--wfc"); }) >= 0)) { Header headRegistry = new Header("Wfc"); headRegistry.AppendHeader(Path.Combine(BasePath, "GLSpecs/WF/wfc.h")); ctx = new RegistryContext("Wfc", headRegistry); glRegistryProcessor = new RegistryProcessor(ctx.Registry, "OpenWF"); GenerateCommandsAndEnums(glRegistryProcessor, ctx); GenerateExtensionsSupportClass(glRegistryProcessor, ctx); GenerateVersionsSupportClass(glRegistryProcessor, ctx); GenerateVbCommands(glRegistryProcessor, ctx); } // OpenWF(D) if ((args.Length == 0) || (Array.FindIndex(args, delegate(string item) { return(item == "--wfd"); }) >= 0)) { Header headRegistry = new Header("Wfd"); headRegistry.AppendHeader(Path.Combine(BasePath, "GLSpecs/WF/wfd.h")); ctx = new RegistryContext("Wfd", headRegistry); glRegistryProcessor = new RegistryProcessor(ctx.Registry, "OpenWF"); GenerateCommandsAndEnums(glRegistryProcessor, ctx); GenerateExtensionsSupportClass(glRegistryProcessor, ctx); GenerateVersionsSupportClass(glRegistryProcessor, ctx); GenerateVbCommands(glRegistryProcessor, ctx); } RegistryDocumentation.CloseLog(); }