sm7125: Fix adaptive brightness not being stable

tirimbino
Ruchit Marathe 2 years ago
parent 6923a2ec80
commit f8422a40eb
  1. 659
      overlay/frameworks/base/core/res/res/values/config.xml

@ -18,90 +18,24 @@
-->
<resources>
<!-- Whether devices suports in-display fingerprint when screen is off -->
<bool name="config_automatic_brightness_available">true</bool>
<bool name="config_supportsScreenOffUdfps">false</bool>
<!-- Whether a software navigation bar should be shown. NOTE: in the future this may be
autodetected from the Configuration. -->
<bool name="config_showNavigationBar">true</bool>
<!-- Boolean indicating if current platform supports HFP inband ringing -->
<bool name="config_bluetooth_hfp_inband_ringing_support">true</bool>
<!-- Boolean indicating if current platform supports BLE peripheral mode -->
<bool name="config_bluetooth_le_peripheral_mode_supported">true</bool>
<!-- Flag specifying whether VoLTE should be available for carrier: independent of
carrier provisioning. If false: hard disabled. If true: then depends on carrier
provisioning, availability etc -->
<bool name="config_carrier_volte_available">true</bool>
<!-- Flag specifying whether VoLTE is available on device -->
<bool name="config_device_volte_available">true</bool>
<!-- Flag specifying whether VT is available on device -->
<bool name="config_carrier_volte_available">false</bool>
<bool name="config_device_volte_available">false</bool>
<bool name="config_device_vt_available">true</bool>
<!-- Flag specifying whether WFC over IMS is available on device -->
<bool name="config_device_wfc_ims_available">true</bool>
<!-- Whether UI for multi user should be shown -->
<bool name="config_device_wfc_ims_available">true</bool>
<bool name="config_enableMultiUserUI">true</bool>
<!-- Maximum number of supported users -->
<integer name="config_multiuserMaximumUsers">4</integer>
<!-- Is the device capable of hot swapping an UICC Card -->
<bool name="config_hotswapCapable">true</bool>
<!-- Flag indicating if the speed up audio on mt call code should be executed -->
<bool name="config_speed_up_audio_on_mt_calls">true</bool>
<!-- Config determines whether to update phone object when voice registration
state changes. Voice radio tech change will always trigger an update of
phone object irrespective of this config -->
<bool name="config_switch_phone_on_voice_reg_state_change">false</bool>
<!-- If this is true, the screen will come on when you unplug usb/power/whatever. -->
<bool name="config_unplugTurnsOnScreen">true</bool>
<!-- Set to true if the wifi display supports compositing content stored
in gralloc protected buffers. For this to be true, there must exist
a protected hardware path for surface flinger to composite and send
protected buffers to the wifi display video encoder.
If this flag is false, we advise applications not to use protected
buffers (if possible) when presenting content to a wifi display because
the content may be blanked.
This flag controls whether the {@link Display#FLAG_SUPPORTS_PROTECTED_BUFFERS}
flag is set for wifi displays.
-->
<bool name="config_wifiDisplaySupportsProtectedBuffers">true</bool>
<!-- Whether WiFi display is supported by this device.
There are many prerequisites for this feature to work correctly.
Here are a few of them:
* The WiFi radio must support WiFi P2P.
* The WiFi radio must support concurrent connections to the WiFi display and
to an access point.
* The Audio Flinger audio_policy.conf file must specify a rule for the "r_submix"
remote submix module. This module is used to record and stream system
audio output to the WiFi display encoder in the media server.
* The remote submix module "audio.r_submix.default" must be installed on the device.
* The device must be provisioned with HDCP keys (for protected content).
-->
<bool name="config_enableWifiDisplay">true</bool>
<!-- Boolean indicating if restoring network selection should be skipped -->
<!-- The restoring is handled by modem if it is true-->
<bool translatable="false" name="skip_restoring_network_selection">true</bool>
<!-- Configure mobile tcp buffer sizes in the form:
rat-name:rmem_min,rmem_def,rmem_max,wmem_min,wmem_def,wmem_max
If no value is found for the rat-name in use, the system default will be applied.
-->
<string-array name="config_mobile_tcp_buffers">
<item>lte:2097152,4194304,8388608,524288,1572864,2097152</item>
<item>lte_ca:2097152,4194304,8388608,4096,1048576,2097152</item>
@ -114,20 +48,6 @@
<item>gprs:4092,8760,11680,4096,8760,11680</item>
<item>evdo:4094,87380,524288,4096,16384,262144</item>
</string-array>
<!-- This string array should be overridden by the device to present a list of network
attributes. This is used by the connectivity manager to decide which networks can coexist
based on the hardware -->
<!-- An Array of "[Connection name],[ConnectivityManager.TYPE_xxxx],
[associated radio-type],[priority],[restoral-timer(ms)],[dependencyMet] -->
<!-- the 5th element "resore-time" indicates the number of milliseconds to delay
before automatically restore the default connection. Set -1 if the connection
does not require auto-restore. -->
<!-- the 6th element indicates boot-time dependency-met value. -->
<!-- NOTE: The telephony module is no longer reading the configuration below for available
APN types. The set of APN types and relevant settings are specified within the telephony
module and are non-configurable. Whether or not data connectivity over a cellular network
is available at all is controlled by the flag: config_moble_data_capable. -->
<string-array translatable="false" name="networkAttributes">
<item>wifi,1,1,1,-1,true</item>
<item>mobile,0,0,0,-1,true</item>
@ -151,42 +71,41 @@
<item>mobile_foc,30,0,2,-1,true</item>
<item>mobile_rcs,31,0,2,-1,true</item>
</string-array>
<!-- This string array should be overridden by the device to present a list of radio
attributes. This is used by the connectivity manager to decide which networks can coexist
based on the hardware -->
<!-- An Array of "[ConnectivityManager connectionType],
[# simultaneous connection types]" -->
<string-array translatable="false" name="radioAttributes">
<item>1,1</item>
<item>0,1</item>
<item>7,1</item>
</string-array>
<!-- Flag indicating whether we should enable the automatic brightness.
Software implementation will be used if config_hardware_auto_brightness_available is not set -->
<bool name="config_automatic_brightness_available">true</bool>
<!-- Array of light sensor lux values to define our levels for auto backlight brightness support.
The N entries of this array define N + 1 control points as follows:
(1-based arrays)
Point 1: (0, value[1]): lux <= 0
Point 2: (level[1], value[2]): 0 < lux <= level[1]
Point 3: (level[2], value[3]): level[2] < lux <= level[3]
...
Point N+1: (level[N], value[N+1]): level[N] < lux
The control points must be strictly increasing. Each control point
corresponds to an entry in the brightness backlight values arrays.
For example, if lux == level[1] (first element of the levels array)
then the brightness will be determined by value[2] (second element
of the brightness values array).
Spline interpolation is used to determine the auto-brightness
backlight values for lux levels between these control points.
Must be overridden in platform specific overlays -->
<integer-array name="config_autoBrightnessDisplayValuesNits">
<item>11</item>
<item>15</item>
<item>22</item>
<item>27</item>
<item>31</item>
<item>35</item>
<item>55</item>
<item>75</item>
<item>95</item>
<item>106</item>
<item>112</item>
<item>119</item>
<item>134</item>
<item>157</item>
<item>220</item>
<item>378</item>
<item>378</item>
<item>468</item>
<item>515</item>
<item>563</item>
<item>610</item>
<item>658</item>
<item>705</item>
<item>753</item>
<item>776</item>
<item>800</item>
<item>800</item>
</integer-array>
<integer-array name="config_autoBrightnessLevels">
<item>1</item>
<item>2</item>
@ -215,10 +134,6 @@
<item>20000</item>
<item>40000</item>
</integer-array>
<!-- An array describing the screen's backlight values corresponding to the brightness
values in the config_screenBrightnessNits array.
This array should be equal in size to config_screenBrightnessBacklight. -->
<integer-array name="config_screenBrightnessBacklight">
<item>0</item>
<item>1</item>
@ -476,55 +391,238 @@
<item>253</item>
<item>254</item>
<item>255</item>
</integer-array>
<!-- Array of desired screen brightness in nits corresponding to the lux values
in the config_autoBrightnessLevels array. As with config_screenBrightnessMinimumNits and
config_screenBrightnessMaximumNits, the display brightness is defined as the measured
brightness of an all-white image.
If this is defined then:
- config_autoBrightnessLcdBacklightValues should not be defined
- config_screenBrightnessNits must be defined
- config_screenBrightnessBacklight must be defined
This array should have size one greater than the size of the config_autoBrightnessLevels
array. The brightness values must be non-negative and non-decreasing. This must be
overridden in platform specific overlays -->
<integer-array name="config_autoBrightnessDisplayValuesNits">
<item>11</item>
<item>15</item>
<item>22</item>
<item>27</item>
<item>31</item>
<item>35</item>
<item>55</item>
<item>75</item>
<item>95</item>
<item>106</item>
<item>112</item>
<item>119</item>
<item>134</item>
<item>157</item>
<item>220</item>
<item>378</item>
<item>256</item>
<item>257</item>
<item>258</item>
<item>259</item>
<item>260</item>
<item>261</item>
<item>262</item>
<item>263</item>
<item>264</item>
<item>265</item>
<item>266</item>
<item>267</item>
<item>268</item>
<item>269</item>
<item>270</item>
<item>271</item>
<item>272</item>
<item>273</item>
<item>274</item>
<item>275</item>
<item>276</item>
<item>277</item>
<item>278</item>
<item>279</item>
<item>280</item>
<item>281</item>
<item>282</item>
<item>283</item>
<item>284</item>
<item>285</item>
<item>286</item>
<item>287</item>
<item>288</item>
<item>289</item>
<item>290</item>
<item>291</item>
<item>292</item>
<item>293</item>
<item>294</item>
<item>295</item>
<item>296</item>
<item>297</item>
<item>298</item>
<item>299</item>
<item>300</item>
<item>301</item>
<item>302</item>
<item>303</item>
<item>304</item>
<item>305</item>
<item>306</item>
<item>307</item>
<item>308</item>
<item>309</item>
<item>310</item>
<item>311</item>
<item>312</item>
<item>313</item>
<item>314</item>
<item>315</item>
<item>316</item>
<item>317</item>
<item>318</item>
<item>319</item>
<item>320</item>
<item>321</item>
<item>322</item>
<item>323</item>
<item>324</item>
<item>325</item>
<item>326</item>
<item>327</item>
<item>328</item>
<item>329</item>
<item>330</item>
<item>331</item>
<item>332</item>
<item>333</item>
<item>334</item>
<item>335</item>
<item>336</item>
<item>337</item>
<item>338</item>
<item>339</item>
<item>340</item>
<item>341</item>
<item>342</item>
<item>343</item>
<item>344</item>
<item>345</item>
<item>346</item>
<item>347</item>
<item>348</item>
<item>349</item>
<item>350</item>
<item>351</item>
<item>352</item>
<item>353</item>
<item>354</item>
<item>355</item>
<item>356</item>
<item>357</item>
<item>358</item>
<item>359</item>
<item>360</item>
<item>361</item>
<item>362</item>
<item>363</item>
<item>364</item>
<item>365</item>
<item>366</item>
<item>367</item>
<item>368</item>
<item>369</item>
<item>370</item>
<item>371</item>
<item>372</item>
<item>373</item>
<item>374</item>
<item>375</item>
<item>376</item>
<item>377</item>
<item>378</item>
<item>379</item>
<item>380</item>
<item>381</item>
<item>382</item>
<item>383</item>
<item>384</item>
<item>385</item>
<item>386</item>
<item>387</item>
<item>388</item>
<item>389</item>
<item>390</item>
<item>391</item>
<item>392</item>
<item>393</item>
<item>394</item>
<item>395</item>
<item>396</item>
<item>397</item>
<item>398</item>
<item>399</item>
<item>400</item>
<item>401</item>
<item>402</item>
<item>403</item>
<item>404</item>
<item>405</item>
<item>406</item>
<item>407</item>
<item>408</item>
<item>409</item>
<item>410</item>
<item>411</item>
<item>412</item>
<item>413</item>
<item>414</item>
<item>415</item>
<item>416</item>
<item>417</item>
<item>418</item>
<item>419</item>
<item>420</item>
<item>421</item>
<item>422</item>
<item>423</item>
<item>424</item>
<item>425</item>
<item>426</item>
<item>427</item>
<item>428</item>
<item>429</item>
<item>430</item>
<item>431</item>
<item>432</item>
<item>433</item>
<item>434</item>
<item>435</item>
<item>436</item>
<item>437</item>
<item>438</item>
<item>439</item>
<item>440</item>
<item>441</item>
<item>442</item>
<item>443</item>
<item>444</item>
<item>445</item>
<item>446</item>
<item>447</item>
<item>448</item>
<item>449</item>
<item>450</item>
<item>451</item>
<item>452</item>
<item>453</item>
<item>454</item>
<item>455</item>
<item>456</item>
<item>457</item>
<item>458</item>
<item>459</item>
<item>460</item>
<item>461</item>
<item>462</item>
<item>463</item>
<item>464</item>
<item>465</item>
<item>466</item>
<item>467</item>
<item>468</item>
<item>515</item>
<item>563</item>
<item>610</item>
<item>658</item>
<item>705</item>
<item>753</item>
<item>776</item>
<item>800</item>
<item>800</item>
<item>469</item>
<item>470</item>
<item>471</item>
<item>472</item>
<item>473</item>
<item>474</item>
<item>475</item>
<item>476</item>
<item>477</item>
<item>478</item>
<item>479</item>
<item>480</item>
<item>481</item>
<item>482</item>
<item>483</item>
<item>484</item>
<item>485</item>
<item>486</item>
</integer-array>
<!-- An array of floats describing the screen brightness in nits corresponding to the backlight
values in the config_screenBrightnessBacklight array. On OLED displays these values
should be measured with an all white image while the display is in the fully on state.
Note that this value should *not* reflect the maximum brightness value for any high
brightness modes but only the maximum brightness value obtainable in a sustainable manner.
This array should be equal in size to config_screenBrightnessBacklight -->
<array name="config_screenBrightnessNits">
<item>2</item>
<item>2.31094</item>
@ -782,6 +880,237 @@
<item>415.74307</item>
<item>417.87027</item>
<item>420</item>
<item>425</item>
<item>426.46628</item>
<item>428.29913</item>
<item>429.7654</item>
<item>431.59824</item>
<item>433.0645</item>
<item>434.89737</item>
<item>436.36365</item>
<item>438.19647</item>
<item>439.66275</item>
<item>441.12903</item>
<item>442.96188</item>
<item>444.42816</item>
<item>446.261</item>
<item>447.72726</item>
<item>449.56012</item>
<item>451.0264</item>
<item>452.85925</item>
<item>454.3255</item>
<item>455.79178</item>
<item>457.62463</item>
<item>459.0909</item>
<item>460.92374</item>
<item>462.39005</item>
<item>464.22287</item>
<item>465.68915</item>
<item>467.522</item>
<item>468.98828</item>
<item>470.8211</item>
<item>472.28738</item>
<item>473.75366</item>
<item>475.58652</item>
<item>477.0528</item>
<item>478.88562</item>
<item>480.3519</item>
<item>482.18475</item>
<item>483.65103</item>
<item>485.48386</item>
<item>486.95016</item>
<item>488.4164</item>
<item>490.24927</item>
<item>491.71555</item>
<item>493.5484</item>
<item>495.01465</item>
<item>496.8475</item>
<item>498.31378</item>
<item>500.14664</item>
<item>501.6129</item>
<item>503.0792</item>
<item>504.91202</item>
<item>506.3783</item>
<item>508.21115</item>
<item>509.67743</item>
<item>511.51025</item>
<item>512.97656</item>
<item>514.8094</item>
<item>516.27563</item>
<item>518.1085</item>
<item>519.57477</item>
<item>521.0411</item>
<item>522.8739</item>
<item>524.3402</item>
<item>526.17303</item>
<item>527.6393</item>
<item>529.47217</item>
<item>530.9384</item>
<item>532.77124</item>
<item>534.23755</item>
<item>535.7038</item>
<item>537.5367</item>
<item>539.0029</item>
<item>540.83575</item>
<item>542.30206</item>
<item>544.1349</item>
<item>545.6012</item>
<item>547.434</item>
<item>548.90027</item>
<item>550.3666</item>
<item>552.1994</item>
<item>553.6657</item>
<item>555.49854</item>
<item>556.9648</item>
<item>558.79767</item>
<item>560.2639</item>
<item>562.09674</item>
<item>563.56305</item>
<item>565.3959</item>
<item>566.8622</item>
<item>568.3284</item>
<item>570.1613</item>
<item>571.62756</item>
<item>573.4604</item>
<item>574.9267</item>
<item>576.7595</item>
<item>578.2258</item>
<item>580.05865</item>
<item>581.5249</item>
<item>582.9912</item>
<item>584.82404</item>
<item>586.29034</item>
<item>588.12317</item>
<item>589.5894</item>
<item>591.4223</item>
<item>592.88855</item>
<item>594.72144</item>
<item>596.1877</item>
<item>597.65393</item>
<item>599.4868</item>
<item>600.95306</item>
<item>602.78595</item>
<item>604.2522</item>
<item>606.085</item>
<item>607.55133</item>
<item>609.38416</item>
<item>610.85046</item>
<item>612.3167</item>
<item>614.14954</item>
<item>615.61584</item>
<item>617.44867</item>
<item>618.915</item>
<item>620.7478</item>
<item>622.21405</item>
<item>624.04694</item>
<item>625.5132</item>
<item>627.34607</item>
<item>628.8123</item>
<item>630.27856</item>
<item>632.11145</item>
<item>633.5777</item>
<item>635.4106</item>
<item>636.87683</item>
<item>638.70966</item>
<item>640.17596</item>
<item>642.0088</item>
<item>643.4751</item>
<item>644.94135</item>
<item>646.7742</item>
<item>648.2405</item>
<item>650.0733</item>
<item>651.5396</item>
<item>653.37244</item>
<item>654.8387</item>
<item>656.6716</item>
<item>658.1378</item>
<item>659.6041</item>
<item>661.43695</item>
<item>662.90326</item>
<item>664.7361</item>
<item>666.20233</item>
<item>668.0352</item>
<item>669.50146</item>
<item>671.3343</item>
<item>672.8006</item>
<item>674.6334</item>
<item>676.09973</item>
<item>677.566</item>
<item>679.3988</item>
<item>680.8651</item>
<item>682.69794</item>
<item>684.16425</item>
<item>685.9971</item>
<item>687.4633</item>
<item>689.2962</item>
<item>690.76245</item>
<item>692.22876</item>
<item>694.0616</item>
<item>695.52783</item>
<item>697.3607</item>
<item>698.82697</item>
<item>700.6598</item>
<item>702.1261</item>
<item>703.9589</item>
<item>705.42523</item>
<item>706.8915</item>
<item>708.72437</item>
<item>710.1906</item>
<item>712.02344</item>
<item>713.48975</item>
<item>715.3226</item>
<item>716.7889</item>
<item>718.6217</item>
<item>720.08795</item>
<item>721.55426</item>
<item>723.3871</item>
<item>724.8534</item>
<item>726.6862</item>
<item>728.15247</item>
<item>729.98535</item>
<item>731.4516</item>
<item>733.2845</item>
<item>734.75073</item>
<item>736.58356</item>
<item>738.04987</item>
<item>739.5161</item>
<item>741.349</item>
<item>742.81525</item>
<item>744.6481</item>
<item>746.1144</item>
<item>747.9472</item>
<item>749.4135</item>
<item>751.24634</item>
<item>752.7126</item>
<item>754.1789</item>
<item>756.0117</item>
<item>757.478</item>
<item>759.31085</item>
<item>760.7771</item>
<item>762.61</item>
<item>764.07623</item>
<item>765.9091</item>
<item>767.37537</item>
<item>768.8416</item>
<item>770.6745</item>
<item>772.14075</item>
<item>773.97363</item>
<item>775.4399</item>
<item>777.2727</item>
<item>778.739</item>
<item>780.57184</item>
<item>782.03815</item>
<item>783.871</item>
<item>785.3372</item>
<item>786.8035</item>
<item>788.63635</item>
<item>790.10266</item>
<item>791.9355</item>
<item>793.40173</item>
<item>795.2346</item>
<item>796.70087</item>
<item>798.5337</item>
<item>800</item>
</array>
<!-- Screen brightness used to dim the screen when the user activity
@ -811,7 +1140,7 @@
the framework from using higher refresh rates, even if display modes with higher refresh
rates are available from hardware composer. Only has an effect if the value is
non-zero. -->
<integer name="config_defaultPeakRefreshRate">60</integer>
<integer name="config_defaultPeakRefreshRate">90</integer>
<!-- When true use the linux /dev/input/event subsystem to detect the switch changes
on the headphone/microphone jack. When false use the older uevent framework. -->

Loading…
Cancel
Save