Skip to content

Instantly share code, notes, and snippets.

Avatar

Esteban Tovagliari est77

View GitHub Profile
@est77
est77 / cmake-static-link.txt
Created May 31, 2019
appleseed link static
View cmake-static-link.txt
@est77
est77 / bindmurmurhash.cpp
Created May 30, 2018
bind murmurhash test
View bindmurmurhash.cpp
//
// This source file is part of appleseed.
// Visit https://appleseedhq.net/ for additional information and resources.
//
// This software is released under the MIT license.
//
// Copyright (c) 2018 Esteban Tovagliari, The appleseedhq Organization
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
View compressed_unit_vector.cpp
/*
Reference:
----------
A Survey of Efficient Representations for Independent Unit Vectors
*/
#include <cmath>
#include <cstdint>
#include <iostream>
@est77
est77 / build.sh
Last active Mar 2, 2017
build appleseed linux
View build.sh
export APPLESEED_DEPENDENCIES="..."
export CMAKE_INCLUDE_PATH=$APPLESEED_DEPENDENCIES/include
export CMAKE_LIBRARY_PATH=$APPLESEED_DEPENDENCIES/lib
export LD_LIBRARY_PATH=$APPLESEED_DEPENDENCIES/lib
mkdir build
cd build
cmake \
View appleseed_python_mesh.py
import appleseed as asr
mesh = asr.MeshObject("my_mesh", {})
print mesh
# Vertices
v0 = asr.Vector3f([0.0, 0.0, 0.0])
v1 = asr.Vector3f([1.0, 0.0, 0.0])
v2 = asr.Vector3f([0.0, 0.0, 1.0])
View gafferseed_area_light.gfr
import Gaffer
import GafferAppleseed
import GafferDispatch
import GafferImage
import GafferOSL
import GafferScene
import IECore
Gaffer.Metadata.registerNodeValue( parent, "serialiser:milestoneVersion", 0, persistent=False )
Gaffer.Metadata.registerNodeValue( parent, "serialiser:majorVersion", 27, persistent=False )
View sandbox.txt
# CMake-gui popup menu.
set (USE_SIMD "OFF" CACHE STRING "Enable SIMD")
set_property (CACHE USE_SIMD PROPERTY STRINGS OFF SSE2 SSE4.2 AVX)
View sss_stuff.cpp
// two C1
template <typename T>
inline T fresnel_first_moment(const T eta)
{
return
eta < T(1.0)
? T(0.919317) + eta * (T(-3.4793) + eta * (T(6.75335) + eta * (T(-7.80989) + eta * (T(4.98554) - eta * T(1.36881)))))
: T(-9.23372) + eta * (T(22.2272) + eta * (T(-20.9292) + eta * (T(10.2291) + eta * (T(-2.54396) + eta * T(0.254913)))));
}
View magic_lut.txt
0.0538163,
0.0590581,
0.0628132,
0.0659693,
0.0687794,
0.0713581,
0.0737684,
0.0760496,
0.0782278,
0.0803216,
View db.csv
0.01 0.2001
0.20202 1.3001
0.40404 2.1001
0.606061 2.8001
0.808081 3.3001
1.0101 3.8001
1.21212 4.3001
1.41414 4.7001
1.61616 5.1001
1.81818 5.4001