Skip to content

Instantly share code, notes, and snippets.

@vicrucann
vicrucann / CMakeLists.txt
Created December 13, 2016 15:34
OpeneSceneGraph: using ray casting to perform drawing on 3D virtual plane
cmake_minimum_required(VERSION 2.8.11)
project(osg-raycast)
set(CMAKE_INCLUDE_CURRENT_DIR ON)
find_package(OpenSceneGraph REQUIRED COMPONENTS osgDB osgGA osgUtil osgViewer)
include_directories(${OPENSCENEGRAPH_INCLUDE_DIRS})
set(SOURCES
@vicrucann
vicrucann / glsl.xml
Created February 17, 2017 23:17
GLSL syntax highlighter for Qt Creator
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE language SYSTEM "language.dtd">
<!-- the version of this file shows the largest supported OpenGL version, second digit is the minor patch level (Y.XP = supports GLSL X.Y0 with patchlevel P -->
<language name="GLSL" section="Sources" extensions="*.glsl;*.vsh;*.vert;*.tcsh;*.tcs;*.tesh;*.tes;*.gsh;*.geo;*.geom;*.fsh;*.frag;*.csh;*.cs" mimetype="text/x-glslsrc" version="4.31" kateversion="2.4" author="Robert Menzel ([email protected])" license="LGPL">
<highlighting>
<!-- ####################################################################################################### keywords -->
<list name="keywordsCompatibility">
<!-- compatibility mode, older GLSL versions -->
<item>attribute</item>
@vicrucann
vicrucann / Tube.cpp
Last active April 10, 2017 17:58
Tube tester file
#include "Tube.h"
#include <osg/Geometry>
#include <osg/Geode>
#include <osg/StateSet>
#include <osg/LineWidth>
#include <osg/BlendFunc>
#include <osg/Material>
#include <osg/LightSource>
@vicrucann
vicrucann / pcl-viewer.cpp
Last active September 15, 2017 18:06
QVTKWidget and depth camera interface running side by side
#include <pcl/PCLGrabber.h>
#include <thread>
#include <mutex>
#include <boost/shared_ptr.hpp>
#include <QApplication>
#include <QMainWindow>
#include <QThread>
#include <QVTKWidget.h>
#include <vtkSmartPointer.h>