This file contains hidden or 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
public void CreateCommonDescriptors() | |
{ | |
AddDesc(ref _apiTypeDescriptor, "rvt:Object:TypeName"); | |
AddDesc(ref _elementLevel, "rvt:Element:Level"); | |
AddDesc(ref _elementLocation, "rvt:Element:Location.Point"); | |
AddDesc(ref _elementLocationEndPointA, "rvt:Element:Location.EndPointA"); | |
AddDesc(ref _elementLocationEndPointB, "rvt:Element:Location.EndPointB"); | |
AddDesc(ref _elementBoundsMin, "rvt:Element:Bounds.Min"); | |
AddDesc(ref _elementBoundsMax, "rvt:Element:Bounds.Max"); |
This file contains hidden or 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
// Schema for BIM data in an efficient columnar EAV format for loading into various tools and libraries. | |
using System.Collections.Generic; | |
namespace BIMOpenSchema; | |
/// <summary> | |
/// Contains all the BIM Data for a federated model. | |
/// We generally don't use this as-is except for serialization. | |
/// This is an EAV data model. It is intended to be denormalized into a set of components | |
/// </summary> |
This file contains hidden or 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
public enum ParameterStorageTypeEnum | |
{ | |
Unknown = 0, | |
Integer = 1, | |
Double = 2, | |
String = 3, | |
ElementId = 4 | |
} | |
[Flags] |
This file contains hidden or 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
// This is a documented and lightly modified version of the Object Schema for VIM Files: | |
// https://github.com/vimaec/vim-format/blob/develop/docs/object-model-schema.json | |
{ | |
// The "Area" table holds data about Revit area elements, including whether the area is gross interior, | |
// its perimeter, and references to its corresponding AreaScheme and Element. Use this table to track and | |
// calculate different kinds of areas within the model. | |
"Area": [ | |
"boolean:IsGrossInterior", | |
"double:Perimeter", |
This file contains hidden or 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 Ara3D.Buffers; | |
using Ara3D.Collections; | |
using Ara3D.NarwhalDB; | |
namespace Ara3D.IfcParser; | |
public class IfcPropertyDataReader | |
{ | |
public IfcPropertyDataReader(IReadOnlyList<ByteSpanBuffer> buffers) | |
{ |
This file contains hidden or 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
/* | |
Modified from https://github.com/ThatOpen/engine_web-ifc/blob/main/src/cpp/web-ifc-test.cpp | |
This is a snippet of code used to properly benchmark Web IFC in C++ | |
https://github.com/ThatOpen/engine_web-ifc for loading files and counting doors. | |
Unlike the previous code, we count the entire file load process. | |
*/ | |
int main(int argc, char* argv[]) | |
{ | |
std::cout << "Web IFC test" << std::endl; | |
std::cout << "# args = " << argc << std::endl; |
This file contains hidden or 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
class ConceptExamples | |
{ | |
Number Lerp(Number a, Number b, double t) | |
=> a * t + b * (1.0 - t); | |
Number Dot(Vector v) | |
=> (v * v).Sum().Sqrt(); | |
Number Sum(Array xs) | |
=> xs.Aggregate((x, y) => x + y); |
This file contains hidden or 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 Plato; | |
#region Groups | |
// https://en.wikipedia.org/wiki/Algebraic_group | |
interface IGroup<T> | |
where T : IGroup<T> | |
{ | |
T GroupOperation(T x); | |
} |
This file contains hidden or 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; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
using UnityEngine; | |
[ExecuteAlways] | |
public class PMoveTowards : MonoBehaviour | |
{ |
This file contains hidden or 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
public interface IAnimationCurve | |
{ | |
double this[double t] { get; } | |
double Duration { get; } | |
} | |
public class AnimationClip<T> : IAnimationClip<T> | |
{ | |
public AnimationClip(IAnimationCurve curve, T from, T to, Func<T, T, double, T> lerp) |
NewerOlder