Skip to content

Instantly share code, notes, and snippets.

Roman Larionov romanlarionov

Block or report user

Report or block romanlarionov

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@romanlarionov
romanlarionov / matrix.h
Created Jul 2, 2018
Single header file for templated matrices.
View matrix.h
#ifndef _MATRIX_H
#define _MATRIX_H
#include <cmath>
#include <algorithm>
#include <cstring>
#include "vector.h"
@romanlarionov
romanlarionov / vector.h
Last active Jan 16, 2019
Single header file for templated vectors.
View vector.h
#ifndef _VECTOR_H
#define _VECTOR_H
#include <iostream>
#include <cmath>
template <class t>
struct Vec4;
@romanlarionov
romanlarionov / CMakeLists.txt
Last active Aug 11, 2019
OpenGL Context Creation Template
View CMakeLists.txt
cmake_minimum_required(VERSION 2.6)
project(OpenGL_APP)
option(GLFW_BUILD_DOCS OFF)
option(GLFW_BUILD_EXAMPLES OFF)
option(GLFW_BUILD_TESTS OFF)
add_subdirectory(deps/glfw)
include_directories("deps/glfw/include"
"deps/glad/include/")
@romanlarionov
romanlarionov / bark.sh
Last active Oct 7, 2016
Makes a computer bark.
View bark.sh
#!/bin/bash
if [[ "$(lsb_release -si)" == "Ubuntu" ]]; then
sudo apt-get -qq - y install gnustep-gui-runtime
fi
while :
do
say "bark"
done
@romanlarionov
romanlarionov / pi.md
Last active Mar 29, 2016
Setting up Raspberry Pi VPN for local network access
View pi.md
@romanlarionov
romanlarionov / gist:07b48c14634cce6d4237
Last active Aug 29, 2015
Point Cloud Rendering Script
View gist:07b48c14634cce6d4237
<html>
<head>
<!-- you can include other scripts here -->
<script src="http://cdnjs.cloudflare.com/ajax/libs/three.js/r69/three.js"></script>
<script src="http://threejs.org/examples/js/controls/TrackballControls.js"></script>
<script src="papertowel.json"></script>
</head>
<body>
<script>
@romanlarionov
romanlarionov / gist:23ed26ad6964ad8dfce7
Last active Aug 29, 2015
PCL Compile Instructions
View gist:23ed26ad6964ad8dfce7
* Remember to install NDK and create a standalone toolchain from that *
https://gist.github.com/Tydus/11109634
* Remember to add in install of OpenGL dev headers on Ubuntu *
``` bash
$ sudo apt-get install libpng-dev libjpeg-dev libxxf86vm1 libxxf86vm-dev libxi-dev libxrandr-dev
$ sudo apt-get install mesa-common-dev
$ sudo apt-get install libpthread-stubs0-dev libgl1-mesa-dev libx11-dev libxrandr-dev libfreetype6-dev libglew1.5-dev libjpeg8-dev libsndfile1-dev libopenal-dev
View BeginningOpenGl.md

Travel Guide to OpenGL

I've figured out several things while trying to extend my knowledge of Computer Graphics.

  1. OpenGL can be a bitch if you don't know what you're doing.
  2. There is no worse pain than to experience CMake without knowing what you're doing.
  3. When walking to the depths of hell, it would be nice to have a travel guide.

And that's what this is, a travel guide.

@romanlarionov
romanlarionov / gist:9632797
Last active Aug 29, 2015
Script for making player face the direction of the mouse cursor.
View gist:9632797
using UnityEngine;
using System.Collections;
public class LookAtMouse : MonoBehaviour {
// speed is the rate at which the object will rotate
public float speed;
void FixedUpdate () {
You can’t perform that action at this time.