Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
| bf10e1ac2e | |||
| d68ac2f4ce |
3 changed files with 64 additions and 2 deletions
|
|
@ -49,8 +49,8 @@ bool ckFaceHasAnyOtherRels(const std::vector<struct result> &results,
|
||||||
auto oth = (r.x == f) ? r.y : r.x;
|
auto oth = (r.x == f) ? r.y : r.x;
|
||||||
all_filecodes.insert(oth.i);
|
all_filecodes.insert(oth.i);
|
||||||
if (r.res == Relation::Equals
|
if (r.res == Relation::Equals
|
||||||
|| r.res == Relation::Included && r.x == f
|
|| (r.res == Relation::Included && r.x == f)
|
||||||
|| r.res == Relation::Includes && r.y == f) {
|
|| (r.res == Relation::Includes && r.y == f)) {
|
||||||
where_exists.insert(oth.i);
|
where_exists.insert(oth.i);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
@ -102,6 +102,8 @@ std::string statements(struct result r, std::vector<struct Model> faces) {
|
||||||
return st("A", B, A);
|
return st("A", B, A);
|
||||||
case Relation::Intersects:
|
case Relation::Intersects:
|
||||||
return st("I", A, B);
|
return st("I", A, B);
|
||||||
|
case Relation::Irrelates:
|
||||||
|
return "";
|
||||||
}
|
}
|
||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
|
|
|
||||||
27
flake.lock
generated
Normal file
27
flake.lock
generated
Normal file
|
|
@ -0,0 +1,27 @@
|
||||||
|
{
|
||||||
|
"nodes": {
|
||||||
|
"nixpkgs": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1787814960,
|
||||||
|
"narHash": "sha256-PYZq1qzCJXC2zGI0mH07vrZBsw6DRBAOX0jN1pPtqOQ=",
|
||||||
|
"owner": "nixos",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"rev": "c27cdad491a991b11ed731760aa2ef8db0cb0410",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nixos",
|
||||||
|
"ref": "nixpkgs-unstable",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"root": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": "nixpkgs"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"root": "root",
|
||||||
|
"version": 7
|
||||||
|
}
|
||||||
33
flake.nix
Normal file
33
flake.nix
Normal file
|
|
@ -0,0 +1,33 @@
|
||||||
|
{
|
||||||
|
description = "Surface relation extractor for OCCT";
|
||||||
|
inputs = {
|
||||||
|
nixpkgs.url = "github:nixos/nixpkgs?ref=nixpkgs-unstable";
|
||||||
|
};
|
||||||
|
|
||||||
|
outputs =
|
||||||
|
{ self, nixpkgs }:
|
||||||
|
let
|
||||||
|
system = "x86_64-linux";
|
||||||
|
pkgs = nixpkgs.legacyPackages.${system};
|
||||||
|
in
|
||||||
|
{
|
||||||
|
devShells.${system}.default = pkgs.mkShell {
|
||||||
|
buildInputs = with pkgs; [
|
||||||
|
cmake
|
||||||
|
opencascade-occt
|
||||||
|
clang
|
||||||
|
];
|
||||||
|
};
|
||||||
|
defaultPackage.x86_64-linux = pkgs.stdenv.mkDerivation {
|
||||||
|
pname = "OcctSurfacer";
|
||||||
|
version = "1.0.0";
|
||||||
|
src = ./.;
|
||||||
|
nativeBuildInputs = [
|
||||||
|
pkgs.cmake
|
||||||
|
pkgs.opencascade-occt
|
||||||
|
];
|
||||||
|
|
||||||
|
cmakeFlags = [ "-DBUILD_TESTING=OFF" ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
Loading…
Reference in a new issue