Home
last modified time | relevance | path

Searched refs:widthRatio (Results 1 – 2 of 2) sorted by relevance

/cts/apps/CtsVerifier/src/com/android/cts/verifier/camera/video/
DCameraVideoActivity.java892 float widthRatio = mNextPreviewSize.width / (float)mPreviewTexWidth; in startPreview() local
895 Log.v(TAG, "startPreview: widthRatio=" + widthRatio + " " + "heightRatio=" + in startPreview()
899 if (heightRatio < widthRatio) { in startPreview()
900 transform.setScale(1, heightRatio / widthRatio); in startPreview()
902 mPreviewTexHeight * (1 - heightRatio / widthRatio) / 2); in startPreview()
904 Log.v(TAG, "startPreview: shrink vertical by " + heightRatio / widthRatio); in startPreview()
907 transform.setScale(widthRatio / heightRatio, 1); in startPreview()
908 transform.postTranslate(mPreviewTexWidth * (1 - widthRatio / heightRatio) / 2, 0); in startPreview()
910 Log.v(TAG, "startPreview: shrink horizontal by " + widthRatio / heightRatio); in startPreview()
/cts/apps/CtsVerifier/src/com/android/cts/verifier/camera/formats/
DCameraFormatsActivity.java514 float widthRatio = mNextPreviewSize.width / (float)mPreviewTexWidth; in startPreview() local
517 if (heightRatio < widthRatio) { in startPreview()
518 transform.setScale(1, heightRatio/widthRatio); in startPreview()
520 mPreviewTexHeight * (1 - heightRatio/widthRatio)/2); in startPreview()
522 transform.setScale(widthRatio/heightRatio, 1); in startPreview()
523 transform.postTranslate(mPreviewTexWidth * (1 - widthRatio/heightRatio)/2, in startPreview()