Skip to content

Instantly share code, notes, and snippets.

View tamasgal's full-sized avatar

Tamas Gal tamasgal

View GitHub Profile
@YukiSakamoto
YukiSakamoto / hdf5_simple.cpp
Created August 23, 2013 13:41
simple example to write hdf5 using c++.
#include <string>
#include <iostream>
#include "H5Cpp.h"
#define MAX_NAME_LENGTH 32
const std::string FileName("SimpleCompound.h5");
const std::string DatasetName("PersonalInformation");
const std::string member_age("Age");
const std::string member_sex("Sex");
const std::string member_name("Name");
#include <iostream>
#include <hdf5.h>
// Constants
const char saveFilePath[] = "test.h5";
const hsize_t ndims = 2;
const hsize_t ncols = 3;
int main()
@deepankarsharma
deepankarsharma / modern_opengl_01_triangle.py
Created August 28, 2012 01:50
Modern opengl using Python
from glfwpy.glfw import (AUTO_POLL_EVENTS, OPENED, OPENGL_CORE_PROFILE,
OPENGL_FORWARD_COMPAT, OPENGL_PROFILE, OPENGL_VERSION_MAJOR,
OPENGL_VERSION_MINOR, WINDOW,
Enable, GetWindowParam, Init, OpenWindow, OpenWindowHint,
SetKeyCallback, SetWindowTitle, SwapBuffers, Terminate)
import numpy as np
from OpenGL.arrays import ArrayDatatype
from OpenGL.GL import (GL_ARRAY_BUFFER, GL_COLOR_BUFFER_BIT,
GL_COMPILE_STATUS, GL_FALSE, GL_FLOAT, GL_FRAGMENT_SHADER,
GL_LINK_STATUS, GL_RENDERER, GL_SHADING_LANGUAGE_VERSION,