Commit Graph

34 Commits

Author SHA1 Message Date
John Koleszar
b72373de79 make: flatten object file directories
Rather than building an object file directory heirarchy matching the
source tree's layout, rename the object files so that the object
file name contains the path in the source file tree. The intent here
is to allow two files in different parts of the source tree to have
the same name and still not collide when put into an ar archive.

Change-Id: Id627737dc95ffc65b738501215f34a995148c5a2
2012-11-15 10:44:58 -08:00
John Koleszar
8959c8b11d Merge with upstream experimental changes (2)
Include upstream changes (variance fixes) into the merged code base.

Change-Id: I4182654c1411c1b15cd23235d3822702613abce1
2012-11-07 14:32:26 -08:00
John Koleszar
2c08c28191 Merge with upstream experimental changes
Include upstream changes (unit test fixes, in particular) into the
merged code base.

Change-Id: I096f8a9d09e2532fbec0c95d7a995ab22fa54b29
2012-11-07 11:46:23 -08:00
John Koleszar
7b8dfcb5a2 Rough merge of master into experimental
Creates a merge between the master and experimental branches. Fixes a
number of conflicts in the build system to allow *either* VP8 or VP9
to be built. Specifically either:

  $ configure --disable-vp9 $ configure --disable-vp8
  --disable-unit-tests

VP9 still exports its symbols and files as VP8, so that will be
resolved in the next commit.

Unit tests are broken in VP9, but this isn't a new issue. They are
fixed upstream on origin/experimental as of this writing, but rebasing
this merge proved difficult, so will tackle that in a second merge
commit.

Change-Id: I2b7d852c18efd58d1ebc621b8041fe0260442c21
2012-11-07 11:30:16 -08:00
James Zern
984734436d Fix variance (signed integer) overflow
In the variance calculations the difference is summed and later squared.
When the sum exceeds sqrt(2^31) the value is treated as a negative when
it is shifted which gives incorrect results.

To fix this we force the multiplication to be unsigned.

The alternative fix is to shift sum down by 4 before multiplying.
However that will reduce precision.

For 16x16 blocks the maximum sum is 65280 and sqrt(2^31) is 46340 (and
change).

This change is based on:
1698234 Missed some variance casts
fea3556 Fix variance overflow

Change-Id: I2c61856cca9db54b9b81de83b4505ea81a050a0f
2012-11-06 23:06:44 -08:00
Jim Bankoski
533470c998 add unit test for datarate control
Adds some basic datarate control tests..

Change-Id: I6eff18aa58ef7cfd14886c6b1e048247cd1ad247
2012-10-29 19:54:06 -07:00
Yunqing Wang
15dffcfefa Add unit test for decoder test_vector_test
Got 61 test vectors from vp8-test-vectors.git
(http://git.chromium.org/gitweb/?p=webm/vp8-test-vectors.git)

Added decoder test vectors downloading in unit tests. Uploaded
the test vectors and their md5 files to WebM website.
  $ gsutil cp *.* gs://downloads.webmproject.org/test_data/libvpx

Added their sha1sum to the test/test-data.sha1 file.

In unit tests, download the test vectors to LIBVPX_TEST_DATA_PATH.

Test_vector_test goes through the test vectors, decodes them, and
compute the md5 checksums. The checksums are compared with the
expected md5 checksums to tell if the decoder decodes correctly.

Change-Id: Ia1e84f9347ddf1d4a02e056c0fee7d28dccfae15
2012-10-22 13:46:11 -07:00
Deb Mukherjee
a7333b0a5b Merge of the TX_16X16 experiment
Change-Id: I22aa803ffff330622cdb77277e7b196a9766f882
2012-10-10 17:05:54 -07:00
Adrian Grange
55cff377dd Merge "Unit Test for Error Resilience Mode" 2012-10-04 17:33:55 -07:00
Ronald S. Bultje
1a89bc04e8 Add a unit test for CQ mode.
Change-Id: I66c391987eabc5ea0159bf4a2a4fd8e8e163872f
2012-10-04 16:38:21 -07:00
Adrian Grange
cc017ca8df Unit Test for Error Resilience Mode
This unit test compares the difference in quality with
error resilience enabled and disabled. The test runs
for all of the one-pass encoding modes.

The test ensures that the effect of turning on error
resilience makes less than a 10% difference in PSNR.

Further cases should be added to do a more comprehensive
test.

Change-Id: I1fc747fc78c9459bc6c74494f4b38308dbed0c32
2012-10-03 14:58:26 -07:00
Scott LaVarnway
96f706655e Added unit test for subtract functions
Patch Set 1: gain familiarity with unit tests... added simple
4x4 subtract test
Patch Set 2: fixed mistakes, parameterized as suggested
Patch Set 3: randomized the source/predictor data


Change-Id: I33432bdf7c9f2a9b8c2533a37106382c2a8209ee
Signed-off-by: Scott LaVarnway <slavarnway@google.com>
2012-09-26 13:45:53 -07:00
Yaowu Xu
c953aeacd4 added encode/decode matching validation to tests
This commit adds the ability of validating matched encoder and
decoder to unit tests.

Change-Id: Ie00d69a42477b6a69b324a6bd134939684f7300b
2012-08-31 13:43:51 -07:00
James Zern
429743c56b fix timestamp calculation rollover w/altref
using large values for the timebase, e.g., {33333, 1000000} could
rollover the timestamp calculation in vp8e_encode as it was not using
64-bit math.

originally reported on ffmpeg's trac:
  https://ffmpeg.org/trac/ffmpeg/ticket/1014

BUG=468

Change-Id: Iedb4e11de086a3dda75097bfaf08f2488e2088d8
2012-08-08 14:30:49 -07:00
Daniel Kang
fed8a1837f 16x16 DCT blocks.
Set on all 16x16 intra/inter modes

Features:
- Butterfly fDCT/iDCT
- Loop filter does not filter internal edges with 16x16
- Optimize coefficient function
- Update coefficient probability function
- RD
- Entropy stats
- 16x16 is a config option

Have not tested with experiments.

hd:     2.60%
std-hd: 2.43%
yt:     1.32%
derf:   0.60%

Change-Id: I96fb090517c30c5da84bad4fae602c3ec0c58b1c
2012-08-02 17:33:10 -07:00
Johann
fbea897d85 Add tests for SAD functions
Change-Id: I018335a08cbb1eca55896c21e36918ed45a4b2a8
2012-07-25 17:11:16 -07:00
Paul Wilkins
903efe8a2f Added unit test of vp8_set_roimap()
Change-Id: I99937cbdd6bfe52b7c8ae42f05526dfc06a602f4
2012-07-24 10:48:44 +01:00
Johann
c0e80959ce Move ACMRandom to acm_random.h
Change-Id: I1d99c56d1e1f521507978737fc661ca90af72507
2012-07-20 14:29:35 -07:00
Yunqing Wang
e61573c5f4 Add unit test for vp8_sixtap_predict functions
This unit test tests vp8_sixtap_predict function against preset
data and random generated data. The test against preset data
checks the correctness of the functions, and the test against
random data checks if the optimized six-tap predictor functions
generate matching result as the c functions. It tests the
following functions:
vp8_sixtap_predict16x16_c
vp8_sixtap_predict16x16_mmx
vp8_sixtap_predict16x16_sse2
vp8_sixtap_predict16x16_ssse3

vp8_sixtap_predict8x8_c
vp8_sixtap_predict8x8_mmx
vp8_sixtap_predict8x8_sse2
vp8_sixtap_predict8x8_ssse3

vp8_sixtap_predict8x4_c
vp8_sixtap_predict8x4_mmx
vp8_sixtap_predict8x4_sse2
vp8_sixtap_predict8x4_ssse3

vp8_sixtap_predict4x4_c
vp8_sixtap_predict4x4_mmx
vp8_sixtap_predict4x4_ssse3

Change-Id: I6de097898ebca34a4c8020aed1e8dde5cd3e493b
2012-07-10 09:56:35 -07:00
John Koleszar
acd147c50c Build unit test driver from the default target
We need an easy way to build the unit test driver without running the
tests. This enables passing options like --gtest_filter to the
executable, which can't be done very cleanly when running under
`make test`.

Fixed a number of compiler errors/warnings when building the tests
in various configurations by Jenkins.

Change-Id: I9198122600bcf02520688e5f052ab379f963b77b
2012-06-29 15:03:50 -07:00
Daniel Kang
26641c74d7 Add 8x8 fDCT unit test.
Also factorize ACMRandom to acm_random.h.

Change-Id: I3b6eeb36fcbf7ae6dd3d2892bc40348f5c17982b
2012-06-29 12:07:18 -07:00
Daniel Kang
58156f1826 Port Yaowu's 4x4 fDCT test.
Also fix unit testing.

Change-Id: Iacdc6f1ec53388e093cda1c13e4379e83d4a6535
2012-06-28 15:48:46 -07:00
Ronald S. Bultje
a742a73655 Enable unit test framework in experimental branch.
Change-Id: I27c98025b2857e2911005a52dd57c46e2524e815
2012-06-26 09:50:20 -07:00
Yaowu Xu
532faf0f1c Added unit test for 4x4 forward dct
Change-Id: I1607676879c29adc0173a3c0355a0e5d8a84fc3b
2012-06-25 17:05:52 -07:00
Jim Bankoski
6c86ef2ea4 Merge "Add unit test for intra prediction." 2012-06-25 14:46:45 -07:00
John Koleszar
d67acd870a Merge changes I94a061eb,If6910fe3
* changes:
  add auto keyframe unit test
  Add support for downloading test data
2012-06-25 12:52:02 -07:00
Ronald S. Bultje
a441b60aa0 Add unit test for intra prediction.
Change-Id: I7dadadeb99bee5a51219f46fe11c760fc294c735
2012-06-25 09:34:10 -07:00
Jim Bankoski
96b6b6bbf0 add auto keyframe unit test
To do so we add a framework for encoding a yv12 file..

Change-Id: I94a061eb916beaf6cde920cf1aaadb6eed10a717
2012-06-23 11:20:41 -07:00
Adrian Grange
c7acd6db5e Added unit test for vp8_post_proc_down_and_across
This is a unit test for the post-processing functions:
- vp8_post_proc_down_and_across_c
- vp8_post_proc_down_and_across_mmx
- vp8_post_proc_down_and_across_xmm

Change-Id: Iec3e690327b17470209c00417835473f6d9a35d6
2012-06-20 16:27:59 -07:00
James Zern
7b0b6a2c41 disable lagged encoding in one-pass
This currently has no effect and can create an artificial lag in e.g.,
realtime.

Change-Id: Ia1c7c6dbe7c6fe82a944f087f1b0d1dbbc0aa1b6
2012-06-13 14:06:34 -07:00
John Koleszar
2fb29ff7f9 Add external resize tests
Adds a test that ensures the application is able to trigger frame size
changes via vpx_codec_enc_config_set()

Change-Id: I231c062e533d75c8d63c5f8a5544650117429a63
2012-05-24 09:38:39 -07:00
John Koleszar
b9180fc049 Add initial keyframe tests
Implements a couple simple tests of the encoder API using the gtest
framework:

  TestDisableKeyframes
  TestForceKeyframe
  TestKeyframeMaxDistance

Change-Id: I38e93fe242fbeb30bb11b23ac12de8ddc291a28d
2012-05-22 15:08:11 -07:00
John Koleszar
2d225689d3 Move all tests to test/ directory
Consolodate the unit tests under vp8/ to the test/ directory

Change-Id: I6d6a0fb60f5e3874a4d6710e9e121dd3e81a93db
2012-05-22 15:00:10 -07:00
John Koleszar
e82d261d10 Build unit tests monolithically
Rework unit tests  to have a single executable rather than many, which
should avoid pollution of the visual studio project namespace, improve
build times, and make it easier to use the gtest test sharding system
when we get these going on the continuous build cluster.

Change-Id: If4c3e5d4b3515522869de6c89455c2a64697cca6
2012-05-22 14:37:30 -07:00