Skip to content

Commit

Permalink
new filter with SubFilter
Browse files Browse the repository at this point in the history
  • Loading branch information
lostjared committed Jan 25, 2019
1 parent 69107ec commit 185f49a
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 5 deletions.
Binary file not shown.
8 changes: 4 additions & 4 deletions Acid.Cam.v2.OSX/ac-filter1.cpp

Large diffs are not rendered by default.

11 changes: 11 additions & 0 deletions Acid.Cam.v2.OSX/ac-filter14.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1095,4 +1095,15 @@ void ac::ColorXorScale(cv::Mat &frame) {
}
static int d = 1;
procPos(d, alpha, alpha_max, 4.1, 0.01);
AddInvert(frame);
}

void ac::ColorXorScaleSubFilter(cv::Mat &frame) {
if(subfilter == -1 || ac::draw_strings[subfilter] == "ColorXorScaleSubFilter")
return;
cv::Mat copy1 = frame.clone(), copy2 = frame.clone();
ColorXorScale(copy1);
CallFilter(subfilter, copy2);
AlphaBlend(copy1, copy2, frame, 0.5);
AddInvert(frame);
}
2 changes: 1 addition & 1 deletion Acid.Cam.v2.OSX/ac-filtercat.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ namespace ac {
std::vector<std::string> svSquare {"SquareSwap","SquareSwap4x2","SquareSwap8x4", "SquareSwap16x8","SquareSwap64x32", "SquareBars","SquareBars8","SquareSwapRand16x8","SquareVertical8","SquareVertical16","SquareVertical_Roll","SquareSwapSort_Roll","SquareVertical_RollReverse","SquareSwapSort_RollReverse", "RandomFilteredSquare","RandomQuads","QuadRandomFilter", "RollRandom", "GridFilter8x", "GridFilter16x", "GridFilter8xBlend", "GridRandom", "GridRandomPixel", "PixelatedSquare", "SmoothSourcePixel", "ColorLines", "Curtain", "RandomCurtain", "RandomCurtainVertical", "CurtainVertical", "SlideFilter","SlideFilterXor", "RandomSlideFilter", "SlideUpDown", "SlideUpDownXor", "SlideUpDownRandom", "SlideSubFilter", "SlideSubUpDownFilter", "FourSquare", "EightSquare", "DiagonalSquare", "DiagonalSquareRandom", "SquareStretchDown", "SquareStretchRight", "SquareStretchUp", "SquareStretchLeft", "ExpandSquareBlendSubFilter", "ExpandSquareSubFilter", "ExpandSquareVerticalSubFilter", "SquareDivideSubFilter", "SquareSubFilter", "SquareSubFilter8", "SquareRandomFilter"};


std::vector<std::string> vSub { "SlideSubFilter", "SubFilter", "ResizeSoftFeedbackSubFilter", "SoftFeedbackSubFilter", "SoftFeedbackResizeSubFilter", "SoftFeedbackResizeSubFilter64", "SoftFeedbackReszieSubFilter64_Negate", "SoftFeedbackReszieSubFilter64_Mirror", "Bitwise_XOR_AlphaSubFilter", "AlphaBlendSubFilter", "GradientSubFilterXor", "XorBlend_SubFilter", "SmoothSubFilterAlphaBlend", "SmoothSubFilterXorBlend", "IntertwineSubFilter", "EveryOtherSubFilter", "RandomSubFilterRandomTimes", "AddToFrameSubFilter", "SmoothSubFilter", "EnergizeSubFilter", "SmoothSubFilter16", "EnergizeSubFilter16", "EnergizeSubFilter32", "SmoothSubFilter32", "HalfAddSubFilter", "HalfXorSubFilter", "ChannelMedianSubFilter", "PixelatedSubFilterSort", "FilteredDifferenceSubFilter", "ExpandSquareSubFilter", "ExpandSquareBlendSubFilter", "ExpandSquareVerticalSubFilter", "MirrorEnergizeSubFilter", "InterRGB_SubFilter", "InterSmoothSubFilter", "StoredFramesAlphaBlend_SubFilter", "BlendSubFilter", "BlendAlphaSubFilter", "Blend_AlphaSubFilter", "FrameMedianBlendSubFilter", "FrameBlurSubFilter", "ImageBlendSubFilter", "ImageBlendXorSubFilter", "ImageCollectionSubFilter", "SubFilterMedianBlend", "DarkCollectionSubFilter", "FlipMedianSubFilter", "FlipMirrorSubFilter", "BlendCombinedValueSubFilter", "BlendSubFilterAlpha", "CollectionXorSourceSubFilter", "BlendReverseSubFilter", "SmoothBlendReverseSubFilter", "MedianBlendBufferSubFilter", "RGBBlendSubFilter", "XorOppositeSubFilter", "BlendSmoothSubFilter", "BlurSmoothSubFilter", "BlurFlipSubFilter", "MedianBlendSubFilterEx", "ShiftFrameSmoothSubFilter", "ShiftFrameStaticXorSubFilter", "RandomSubFilter", "BlendWithFrameSubFilter", "AlphaBlendWithFrameSubFilter", "AlphaXorBlendWithFrameSubFilter", "XorBlendSubFilter", "SmoothMedianRotateSubFilter", "XorSubFilter", "XorAlphaSubFilter", "BlurXorAlphaSubFilter", "ImageAlphaXorMedianSubFilter", "ImageSmoothAlphaXorSubFilter", "ImageXorSubFilter", "ImageAlphaXorSubFilter", "BlendWithRainbowSubFilter","BlendWithJetSubFilter", "ColormapBlendSubFilter", "RandomColorMapAlphaBlendSubFilter", "RandomOrderMedianBlendSubFilter", "MirrorOrderSubFilter","FilterStrobeSubFilter", "BlendImageWithSubFilter", "BlendImageWithSubFilterAlpha", "AndImageSubFilterXor", "AlphaBlendImageSubFilterXor", "AlphaBlendImageSubFilterXorRev", "ParticleReleaseSubFilter", "ParticleReleaseImageSubFilter", "ImageEnergySubFilter", "ImageDistortionSubFilter", "ReverseSubFilterBlend", "ReverseSubFilterXor", "ImageReverseSubFilter", "ImageSmoothMedianSubFilter", "MatrixCollectionSubFilter", "MatrixCollectionImageSubFilter", "TrailsSubFilter", "TrailsSubFilter32", "CompareWithSubFilter", "ColorTransitionSubFilter", "CurtainSubFilter", "RandomTrailsSubFilter", "Filter8_SubFilter", "SquareRandomSubFilter", "ColorExpandSubFilter", "RotateImageSubFilter", "FlipStrobeSubFilter", "MirrorSidesSubFilter", "MedianFrameAlphaBlendSubFilter", "MedianSubFilter"};
std::vector<std::string> vSub { "SlideSubFilter", "SubFilter", "ResizeSoftFeedbackSubFilter", "SoftFeedbackSubFilter", "SoftFeedbackResizeSubFilter", "SoftFeedbackResizeSubFilter64", "SoftFeedbackReszieSubFilter64_Negate", "SoftFeedbackReszieSubFilter64_Mirror", "Bitwise_XOR_AlphaSubFilter", "AlphaBlendSubFilter", "GradientSubFilterXor", "XorBlend_SubFilter", "SmoothSubFilterAlphaBlend", "SmoothSubFilterXorBlend", "IntertwineSubFilter", "EveryOtherSubFilter", "RandomSubFilterRandomTimes", "AddToFrameSubFilter", "SmoothSubFilter", "EnergizeSubFilter", "SmoothSubFilter16", "EnergizeSubFilter16", "EnergizeSubFilter32", "SmoothSubFilter32", "HalfAddSubFilter", "HalfXorSubFilter", "ChannelMedianSubFilter", "PixelatedSubFilterSort", "FilteredDifferenceSubFilter", "ExpandSquareSubFilter", "ExpandSquareBlendSubFilter", "ExpandSquareVerticalSubFilter", "MirrorEnergizeSubFilter", "InterRGB_SubFilter", "InterSmoothSubFilter", "StoredFramesAlphaBlend_SubFilter", "BlendSubFilter", "BlendAlphaSubFilter", "Blend_AlphaSubFilter", "FrameMedianBlendSubFilter", "FrameBlurSubFilter", "ImageBlendSubFilter", "ImageBlendXorSubFilter", "ImageCollectionSubFilter", "SubFilterMedianBlend", "DarkCollectionSubFilter", "FlipMedianSubFilter", "FlipMirrorSubFilter", "BlendCombinedValueSubFilter", "BlendSubFilterAlpha", "CollectionXorSourceSubFilter", "BlendReverseSubFilter", "SmoothBlendReverseSubFilter", "MedianBlendBufferSubFilter", "RGBBlendSubFilter", "XorOppositeSubFilter", "BlendSmoothSubFilter", "BlurSmoothSubFilter", "BlurFlipSubFilter", "MedianBlendSubFilterEx", "ShiftFrameSmoothSubFilter", "ShiftFrameStaticXorSubFilter", "RandomSubFilter", "BlendWithFrameSubFilter", "AlphaBlendWithFrameSubFilter", "AlphaXorBlendWithFrameSubFilter", "XorBlendSubFilter", "SmoothMedianRotateSubFilter", "XorSubFilter", "XorAlphaSubFilter", "BlurXorAlphaSubFilter", "ImageAlphaXorMedianSubFilter", "ImageSmoothAlphaXorSubFilter", "ImageXorSubFilter", "ImageAlphaXorSubFilter", "BlendWithRainbowSubFilter","BlendWithJetSubFilter", "ColormapBlendSubFilter", "RandomColorMapAlphaBlendSubFilter", "RandomOrderMedianBlendSubFilter", "MirrorOrderSubFilter","FilterStrobeSubFilter", "BlendImageWithSubFilter", "BlendImageWithSubFilterAlpha", "AndImageSubFilterXor", "AlphaBlendImageSubFilterXor", "AlphaBlendImageSubFilterXorRev", "ParticleReleaseSubFilter", "ParticleReleaseImageSubFilter", "ImageEnergySubFilter", "ImageDistortionSubFilter", "ReverseSubFilterBlend", "ReverseSubFilterXor", "ImageReverseSubFilter", "ImageSmoothMedianSubFilter", "MatrixCollectionSubFilter", "MatrixCollectionImageSubFilter", "TrailsSubFilter", "TrailsSubFilter32", "CompareWithSubFilter", "ColorTransitionSubFilter", "CurtainSubFilter", "RandomTrailsSubFilter", "Filter8_SubFilter", "SquareRandomSubFilter", "ColorExpandSubFilter", "RotateImageSubFilter", "FlipStrobeSubFilter", "MirrorSidesSubFilter", "MedianFrameAlphaBlendSubFilter", "MedianSubFilter", "ColorXorScaleSubFilter"};


void SortFilters() {
Expand Down
1 change: 1 addition & 0 deletions Acid.Cam.v2.OSX/ac.h
Original file line number Diff line number Diff line change
Expand Up @@ -900,6 +900,7 @@ namespace ac {
void MedianFrameAlphaBlendSubFilter(cv::Mat &frame);
void MedianSubFilter(cv::Mat &frame);
void ColorXorScale(cv::Mat &frame);
void ColorXorScaleSubFilter(cv::Mat &frame);
// No filter (do nothing)
void NoFilter(cv::Mat &frame);
// Alpha blend with original image
Expand Down

0 comments on commit 185f49a

Please sign in to comment.