eC
Comments
by Jérôme Jacovella-St-Louis
C-style object-oriented language for simple native cross-platform development.
  • Compiles Natively Just Like C
  • C superset, C ABI
  • Modules, an alternative to header files
  • Module restricted access control
  • Powerful and Extensible Type System
  • Object Oriented Features
    • Instantiation
    • Properties
    • Classes
    • Structs
    • Subclassing
    • Generics
    • Containers
    • Unit Types
    • Conversion Properties
    • Context-sensitive Enumerations
    • Bit Collection Classes
    • Memory Management
  • Dynamic Module Importing
  • Reflective Object Model

Ecere SDK

The open-source Ecere Cross-Platform SDK is written in eC and offers GUI, 2D/3D Graphics, Networking, an IDE, and a lot more...

Documentation

Free Open-Source Software

The eC compiler is released as part of the Ecere SDK under a revised BSD license.

import "ecere"

class MyApp : GuiApplication
{
   driver = "OpenGL";
};

Camera camera
{
   fixed,
   position = Vector3D { 0, 0, -350 },
   orientation = Euler { 0, 0, 0 },
   fov = 53;
};

Light light
{
   diffuse = lightCoral;
   orientation = Euler { pitch = 10, yaw = 30 };
};

class Hello3D : Window
{
   text = "Hello, 3D";
   background = black;
   borderStyle = sizable;
   hasMaximize = true;
   hasMinimize = true;
   hasClose = true;
   clientSize = { 304, 162 };

   Cube cube { };

   bool OnLoadGraphics()
   {
      cube.Create(displaySystem);
      cube.transform.scaling = { 100, 100, 100 };
      cube.transform.orientation = Euler { 50, 30, 50 };
      cube.UpdateTransform();
      return true;
   }

   void OnResize(int w, int h)
   {
      camera.Setup(w, h, null);
      camera.Update();
   }

   void OnRedraw(Surface surface)
   {
      surface.Clear(depthBuffer);
      display.SetLight(0, light);
      display.SetCamera(surface, camera);
      display.DrawObject(cube);
      display.SetCamera(surface, null);
   }
}

Hello3D hello3D {};
Information updated 07/22/18
View Comments