Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added sse2neon for arm compilation. #126

Merged
merged 2 commits into from
Jan 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,7 @@ CMakeFiles
Makefile
cmake_install.cmake
install_manifest.txt

# Don't include the build directory and compiled Mac dynamic libraries.
build
*.dylib
6 changes: 6 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/CMakeModules/")

include (FindSSE)
include (GNUInstallDirs)
# include (ExternalProject) # There must be a nicer way to include this
# include (sse2neon)
find_package(OpenMP)

set(MAJOR_VERSION 1)
Expand All @@ -30,6 +32,10 @@ if(NOT WIN32)
add_definitions(-fPIC)
endif()

if(APPLE)
add_definitions(-march=armv8-a+fp+simd+crypto+crc)
endif(APPLE)

### ORC is not used in any active code at the moment ###
# I tried it with 0.4.14
# 0.4.10 did not work (not all opcode implemented)
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# VidStab

[![C/C++ CI](https://github.com/georgmartius/vid.stab/actions/workflows/c-cpp.yml/badge.svg)](https://github.com/georgmartius/vid.stab/actions/workflows/c-cpp.yml)

Vidstab is a video stabilization library which can be plugged-in with Ffmpeg and Transcode.

**Why is it needed**
Expand Down
7 changes: 7 additions & 0 deletions src/motiondetect_opt.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,13 @@
#define SSE2_CMP_SUM_ROWS 8
#endif

#ifdef __ARM_NEON__
#include "sse2neon.h"
#define USE_SSE2
#define USE_SSE2_CMP_HOR
#define SSE2_CMP_SUM_ROWS 8
#endif

#ifdef USE_SSE2
/**
\see contrastSubImg using SSE2 optimization, Planar (1 byte per channel) only
Expand Down
Loading