Skip to content

Latest commit

 

History

History
42 lines (30 loc) · 876 Bytes

readme.md

File metadata and controls

42 lines (30 loc) · 876 Bytes

Image Warp

This repo is implementation image warp in c function, there are floating and fixed function for warping image.

I reference the python function in https://github.com/eborboihuc/rotate_3d . And you may refine the cal_trans_matrix input in main.cpp to get the warping matrix.

// the input rotation order, roll, pitch, yaw in degree
cal_trans_matrix(0.0, 0.0,10, image_width, image_height, trans_matrix);

usage

mkdir build
cd build
cmake ..
cmake --build .

and there will be prebuilt/image_warp.exe

run

./image_warp.exe ../lean.png

result

--------------------------
Image warp in float operation:
Time measured: 0.014680 seconds.
--------------------------
Image warp in fixed-point operation:
Time measured: 0.008530 seconds.

rotate yaw 10 degree

test_fixed