-
Potential solution: https://www.gamedev.net/forums/topic/484984-skeletal-animation---non-uniform-scale/
-
Description: https://answers.unrealengine.com/questions/158091/weird-scaling-behaviour-of-actor-hierarchy.html
-
https://www.marti.works/transform-class-position-rotation-and-scale/
-
For constraining point to axis
-
For shoemake constraint
-
Existing libraries
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace Compiler { | |
public delegate void PrintErrorFunction(string message); | |
public class Location { | |
public string File { get; protected set; } | |
public int Line { get; protected set; } | |
public int Column { get; protected set; } | |
public Location(string file, int line, int column) { | |
File = file; | |
Line = line; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using UnityEditor; | |
using System.Collections; | |
// an Editor method to create a cone primitive (so far no end caps) | |
// the top center is placed at (0/0/0) | |
// the bottom center is placed at (0/0/length) | |
// if either one of the radii is 0, the result will be a cone, otherwise a truncated cone | |
// note you will get inevitable breaks in the smooth shading at cone tips | |
// note the resulting mesh will be created as an asset in Assets/Editor |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Trig approximations from: http://www.ganssle.com/approx.htm | |
#include <windows.h> | |
#include <cmath> | |
#include <iostream> | |
#include <iomanip> | |
#define WINDOW_WIDTH 800 | |
#define WINDOW_HEIGHT 600 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// From: https://code.google.com/archive/p/kri/wikis/Quaternions.wiki | |
struct Spatial { | |
vec4 pos,rot; | |
}; | |
//rotate vector | |
vec3 qrot(vec4 q, vec3 v) { | |
return v + 2.0*cross(q.xyz, cross(q.xyz,v) + q.w*v); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#define _CRT_SECURE_NO_WARNINGS | |
#include "Font.h" | |
#include <tuple> | |
using std::vector; | |
using std::tuple; | |
using std::get; | |
void DrawPixel(i32 x, i32 y, u8 r, u8 g, u8 b); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "SkeletonVisualizer.h" | |
#if __linux | |
#include <GL/glew.h> | |
#include <GL/gl.h> | |
#elif WIN32 | |
#include <GL/glew.h> | |
#include <Windows.h> | |
#include <tchar.h> | |
#include <gl/gl.h> | |
#else |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
namespace Brainfuck { | |
class MainClass { | |
public static void Main (string[] args) { | |
Console.WriteLine ("Enter Command Buffer: "); | |
string commandBuffer = Console.ReadLine (); | |
int[] memory = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0}; | |
int memoryPointer = 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/////////////////////////////////////////////////////////////////////////// | |
// | |
// MODULE: MOUSINFO.C | |
// | |
// DESCRIPTION: SDK sample for handling the WM_MOUSEWHEEL message and | |
// the TrackMouseEvent() API. | |
// | |
// Applet displays MouseButton, MouseWheel, MouseMovement, and | |
// any mouse messages in the title bar. | |
// |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "memory.h" | |
#if defined(MEM_PLATFORM_WINDOWS) | |
#include <windows.h> | |
mem_cfunc void PrintDebugString(const char* str) { | |
OutputDebugStringA(str); | |
} | |
#ifdef _DEBUG | |
#define MemInternal_Assert(cond) if (!(cond)) {*(u8*)0 = 0;} |
NewerOlder