[FFmpeg-cvslog] avutil/softfloat: Add more tests for the normalization
Michael Niedermayer
git at videolan.org
Fri Jun 5 13:11:24 CEST 2015
ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Fri Jun 5 12:57:06 2015 +0200| [904ea60afacd78ff106422019b0ef5032ff7a195] | committer: Michael Niedermayer
avutil/softfloat: Add more tests for the normalization
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=904ea60afacd78ff106422019b0ef5032ff7a195
---
libavutil/softfloat.c | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/libavutil/softfloat.c b/libavutil/softfloat.c
index b6e1f35..37dd758 100644
--- a/libavutil/softfloat.c
+++ b/libavutil/softfloat.c
@@ -93,6 +93,16 @@ int main(void){
sf3 = av_add_sf(sf3, sf2);
printf("test3 softfloat: %.10lf (0x%08x %d)\n", (double)av_sf2double(sf3), sf3.mant, sf3.exp);
+ sf1 = av_int2sf(0xFFFFFFF0, 0);
+ printf("test4 softfloat: %.10lf (0x%08x %d)\n", (double)av_sf2double(sf1), sf1.mant, sf1.exp);
+ sf1 = av_int2sf(0x00000010, 0);
+ printf("test4 softfloat: %.10lf (0x%08x %d)\n", (double)av_sf2double(sf1), sf1.mant, sf1.exp);
+
+ sf1 = av_int2sf(0x1FFFFFFF, 0);
+ printf("test4 softfloat: %.10lf (0x%08x %d)\n", (double)av_sf2double(sf1), sf1.mant, sf1.exp);
+ sf1 = av_int2sf(0xE0000001, 0);
+ printf("test4 softfloat: %.10lf (0x%08x %d)\n", (double)av_sf2double(sf1), sf1.mant, sf1.exp);
+
return 0;
}
More information about the ffmpeg-cvslog
mailing list