Skip to content

Commit

Permalink
version 0.3.0-rc12
Browse files Browse the repository at this point in the history
Continue to fine-tune the nhw_kernel weights
  • Loading branch information
rcanut committed Feb 17, 2024
1 parent f5270c7 commit 99ba959
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 11 deletions.
18 changes: 10 additions & 8 deletions encoder/image_processing.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
****************************************************************************
* NHW Image Codec *
* file: image_processing.c *
* version: 0.3.0-rc11 *
* last update: $ 02062024 nhw exp $ *
* version: 0.3.0-rc12 *
* last update: $ 02172024 nhw exp $ *
* *
****************************************************************************
****************************************************************************
Expand Down Expand Up @@ -929,7 +929,7 @@ void pre_processing(image_buffer *im)
}
else
{
nhw_kernel[scan-1]=sharpn2+21;
nhw_kernel[scan-1]= 5000; //sharpn2+21;

if (t3==1) t3 = 2;
else t3 = 0;
Expand All @@ -945,7 +945,7 @@ void pre_processing(image_buffer *im)
}
else
{
nhw_kernel[scan-1]= -(sharpn2+21);
nhw_kernel[scan-1]= -5000; //-(sharpn2+21);

if (t4==1) t4 = 2;
else t4 = 0;
Expand All @@ -965,7 +965,7 @@ void pre_processing(image_buffer *im)
}
else
{
nhw_kernel[scan]=sharpn2+21;
nhw_kernel[scan]= 5000; //sharpn2+21;

if (t5==1) t5 = 2;
else t5 = 0;
Expand All @@ -981,7 +981,7 @@ void pre_processing(image_buffer *im)
}
else
{
nhw_kernel[scan]= -(sharpn2+21);
nhw_kernel[scan]= -5000; //-(sharpn2+21);

if (t6==1) t6 = 2;
else t6 = 0;
Expand Down Expand Up @@ -1013,7 +1013,7 @@ void pre_processing(image_buffer *im)
}
else
{
nhw_kernel[scan]=sharpn2+21;
nhw_kernel[scan]= 5000; //sharpn2+21;

if (t5==1) t5 = 2;
else t5 = 0;
Expand All @@ -1029,7 +1029,7 @@ void pre_processing(image_buffer *im)
}
else
{
nhw_kernel[scan]= -(sharpn2+21);
nhw_kernel[scan]= -5000; //-(sharpn2+21);

if (t6==1) t6 = 2;
else t6 = 0;
Expand Down Expand Up @@ -1233,6 +1233,8 @@ void pre_processing(image_buffer *im)

count= nhw_kernel[scan];

if (abs(res)>4000 || abs(count)>4000) continue;

if (abs(res)>sharpness && abs(res)<=(sharpness+20) && abs(count)>sharpness && abs(count)<=(sharpness+20) )
{
if (nhw_sharp_on[scan-1]!=1 && nhw_sharp_on[scan]!=1)
Expand Down
6 changes: 3 additions & 3 deletions encoder/nhw_encoder_cli.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
****************************************************************************
* NHW Image Codec *
* file: nhw_encoder_cli.c *
* version: 0.3.0-rc11 *
* last update: $ 02062024 nhw exp $ *
* version: 0.3.0-rc12 *
* last update: $ 02172024 nhw exp $ *
* *
****************************************************************************
****************************************************************************
Expand Down Expand Up @@ -50,7 +50,7 @@
#include "codec.h"

#define PROGRAM "nhw-enc"
#define VERSION "0.3.0-rc11"
#define VERSION "0.3.0-rc12"

#define NHW_QUALITY_MIN LOW20
#define NHW_QUALITY_MAX HIGH3
Expand Down

0 comments on commit 99ba959

Please sign in to comment.