Skip to content

Commit

Permalink
Add readme
Browse files Browse the repository at this point in the history
  • Loading branch information
Endilll authored May 9, 2020
1 parent 94e2945 commit 5b7a890
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# ExprCpp
Same as `std.Expr()`, but takes arbitrary C++ functions instead of MaskTools RPN expressions.

## Example
```
user_func = '''
int func(int x, int y) {
return x/4 + y/4;
}
'''
clip00 = core.endill.expr_cpp(clip00, clip00, user_func)
```

## Building Prerequsites for Linux
* Compiler with C++17 support
* CMake 3.16.3+
* LLVM 10 (`llvm-10-dev`)
* Clang 10 (`libclang-cpp10-dev`)
```
mkdir build
cd build
cmake ..
cmake --build .
```

## Building for Windows
Only as a part of LLVM build, because Windows distibution of LLVM doesn't expose C++ interface.

0 comments on commit 5b7a890

Please sign in to comment.