Timus 1225. Flags dp

1225. Flags
Time Limit: 1.0 second
Memory Limit: 16 MB
On the Day of the Flag of Russia a shop-owner decided to decorate the show-window of his shop with textile stripes of white, blue and red colors. He wants to satisfy the following conditions:
Stripes of the same color cannot be placed next to each other.
A blue stripe must always be placed between a white and a red or between a red and a white one.
Determine the number of the ways to fulfill his wish.
Example. For N = 3 result is following:

Input
N, the number of the stripes, 1 ≤ N ≤ 45.
Output
M, the number of the ways to decorate the shop-window.
Sample

input 
3

output

4

 

 

 

 

discuss里有人这么说:

use fibonacci
1,1,2,3,5,8,13...

answer = fibonacci(3)*2;

不明白……但这么做答案是对的。

我用的是dp

 

 

* index: 2 name: <alsa_output.platform-dp0-sound.multichannel-output> driver: <module-alsa-card.c> flags: HARDWARE DECIBEL_VOLUME LATENCY DYNAMIC_LATENCY state: RUNNING suspend cause: (none) priority: 9000 volume: front-left: 46530 / 71% / -8.92 dB, front-right: 46530 / 71% / -8.92 dB balance 0.00 base volume: 65536 / 100% / 0.00 dB volume steps: 65537 muted: no current latency: 0.00 ms max request: 344 KiB max rewind: 344 KiB monitor source: 4 sample spec: s16le 2ch 48000Hz channel map: front-left,front-right 立体声 used by: 1 linked by: 1 configured latency: 1837.50 ms; range is 0.50 .. 1837.50 ms card: 0 <alsa_card.platform-dp0-sound> module: 6 properties: alsa.resolution_bits = "16" device.api = "alsa" device.class = "sound" alsa.class = "generic" alsa.subclass = "generic-mix" alsa.name = "rockchip,dp0 spdif-hifi-0" alsa.id = "rockchip,dp0 spdif-hifi-0" alsa.subdevice = "0" alsa.subdevice_name = "subdevice #0" alsa.device = "0" alsa.card = "0" alsa.card_name = "rockchip,dp0" alsa.long_card_name = "rockchip,dp0" device.bus_path = "platform-dp0-sound" sysfs.path = "/devices/platform/dp0-sound/sound/card0" device.form_factor = "internal" device.string = "hw:0" device.buffering.buffer_size = "352800" device.buffering.fragment_size = "176400" device.access_mode = "mmap+timer" device.profile.name = "multichannel-output" device.profile.description = "多声道" device.description = "内置音频 多声道" module-udev-detect.discovered = "1" device.icon_name = "audio-card" ports: multichannel-output: 多声道输出 (priority 0, latency offset 0 usec, available: unknown) properties: active port: <multichannel-output>
07-15
Transcript Start Time: 21:10:55, 01 Nov 2025 й ׼ʱ Current Directory: "C:\Users\PC" Build Time: Nov 28 2022 09:52:02 EST Executable Path: D:/Program Files/ANSYS Inc/v231/fluent/ntbin/win64/fluent.exe --------------------------------------------------------------------------------------- ID Hostname Core O.S. PID Vendor --------------------------------------------------------------------------------------- n23 DESKTOP-NE8T1C1 24/192 Windows-x64 15788 AMD EPYC 7K62 48-Core Processor n22 DESKTOP-NE8T1C1 23/192 Windows-x64 15344 AMD EPYC 7K62 48-Core Processor n21 DESKTOP-NE8T1C1 22/192 Windows-x64 26384 AMD EPYC 7K62 48-Core Processor n20 DESKTOP-NE8T1C1 21/192 Windows-x64 30132 AMD EPYC 7K62 48-Core Processor n19 DESKTOP-NE8T1C1 20/192 Windows-x64 19868 AMD EPYC 7K62 48-Core Processor n18 DESKTOP-NE8T1C1 19/192 Windows-x64 15820 AMD EPYC 7K62 48-Core Processor n17 DESKTOP-NE8T1C1 18/192 Windows-x64 26732 AMD EPYC 7K62 48-Core Processor n16 DESKTOP-NE8T1C1 17/192 Windows-x64 13972 AMD EPYC 7K62 48-Core Processor n15 DESKTOP-NE8T1C1 16/192 Windows-x64 27624 AMD EPYC 7K62 48-Core Processor n14 DESKTOP-NE8T1C1 15/192 Windows-x64 28196 AMD EPYC 7K62 48-Core Processor n13 DESKTOP-NE8T1C1 14/192 Windows-x64 25044 AMD EPYC 7K62 48-Core Processor n12 DESKTOP-NE8T1C1 13/192 Windows-x64 24332 AMD EPYC 7K62 48-Core Processor n11 DESKTOP-NE8T1C1 12/192 Windows-x64 29720 AMD EPYC 7K62 48-Core Processor n10 DESKTOP-NE8T1C1 11/192 Windows-x64 25208 AMD EPYC 7K62 48-Core Processor n9 DESKTOP-NE8T1C1 10/192 Windows-x64 24040 AMD EPYC 7K62 48-Core Processor n8 DESKTOP-NE8T1C1 9/192 Windows-x64 23536 AMD EPYC 7K62 48-Core Processor n7 DESKTOP-NE8T1C1 8/192 Windows-x64 26540 AMD EPYC 7K62 48-Core Processor n6 DESKTOP-NE8T1C1 7/192 Windows-x64 25548 AMD EPYC 7K62 48-Core Processor n5 DESKTOP-NE8T1C1 6/192 Windows-x64 18216 AMD EPYC 7K62 48-Core Processor n4 DESKTOP-NE8T1C1 5/192 Windows-x64 27328 AMD EPYC 7K62 48-Core Processor --------------------------------------------------------------------------------------- ID Hostname Core O.S. PID Vendor --------------------------------------------------------------------------------------- n3 DESKTOP-NE8T1C1 4/192 Windows-x64 29204 AMD EPYC 7K62 48-Core Processor n2 DESKTOP-NE8T1C1 3/192 Windows-x64 22276 AMD EPYC 7K62 48-Core Processor n1 DESKTOP-NE8T1C1 2/192 Windows-x64 29504 AMD EPYC 7K62 48-Core Processor n0* DESKTOP-NE8T1C1 1/192 Windows-x64 21488 AMD EPYC 7K62 48-Core Processor host DESKTOP-NE8T1C1 Windows-x64 24364 AMD EPYC 7K62 48-Core Processor MPI Option Selected: intel Selected system interconnect: default --------------------------------------------------------------------------------------- Cortex Process ID: 28148 License Server Path: 1055@localhost Note: Rank = 0: Process affinity not being set (9). Note: Rank = 1: Process affinity not being set (9). Note: Rank = 2: Process affinity not being set (9). Note: Rank = 3: Process affinity not being set (9). Note: Rank = 4: Process affinity not being set (9). Note: Rank = 5: Process affinity not being set (9). Note: Rank = 6: Process affinity not being set (9). Note: Rank = 7: Process affinity not being set (9). Note: Rank = 8: Process affinity not being set (9). Note: Rank = 9: Process affinity not being set (9). Note: Rank = 10: Process affinity not being set (9). Note: Rank = 11: Process affinity not being set (9). Note: Rank = 12: Process affinity not being set (9). Note: Rank = 13: Process affinity not being set (9). Note: Rank = 14: Process affinity not being set (9). Note: Rank = 15: Process affinity not being set (9). Note: Rank = 16: Process affinity not being set (9). Note: Rank = 17: Process affinity not being set (9). Note: Rank = 18: Process affinity not being set (9). Note: Rank = 19: Process affinity not being set (9). Note: Rank = 20: Process affinity not being set (9). Note: Rank = 21: Process affinity not being set (9). Note: Rank = 22: Process affinity not being set (9). Note: Rank = 23: Process affinity not being set (9). Reading setting file in cache: "G:\10.30\wj_files\dp0\FFF\Fluent\FFF.1.set" Reading "\"| gunzip -c \\"G:\10.30\wj_files\dp0\FFF\Fluent\FFF.1-Setup-Output.cas.gz\\"\""... Buffering for file scan... 2607716 mixed cells, zone 3, binary. Warning: reading 20 partition grid onto 24 compute node machine; will auto partition. 2607716 cell partition ids, zone 3, 20 partitions, binary. 213025 triangular wall faces, zone 1, binary. 5160670 mixed interior faces, zone 2, binary. 141 triangular pressure-inlet faces, zone 6, binary. 114 triangular pressure-outlet faces, zone 7, binary. 31782 triangular wall faces, zone 8, binary. 6258 triangular wall faces, zone 9, binary. 14808 triangular wall faces, zone 10, binary. 2306 triangular wall faces, zone 11, binary. 556980 nodes, binary. 556980 node flags, binary. Building... mesh auto partitioning mesh by Metis (fast), distributing mesh parts........................, faces........................, nodes........................, cells........................, bandwidth reduction using Reverse Cuthill-McKee: 110780/3558 = 31.1355 materials, interface, domains, mixture zones, gudingjiechu facesize1 facesize moving outlet interior-geom_fluid wall-geom_fluid intlet geom_fluidSetting geom_fluid (mixture) ... Done. Setting zone id of geom_fluid to 3. Setting zone id of intlet to 6. Setting zone id of wall-geom_fluid to 1. Setting zone id of interior-geom_fluid to 2. Setting zone id of outlet to 7. Setting zone id of moving to 8. Setting zone id of facesize to 9. Setting zone id of facesize1 to 10. Setting zone id of gudingjiechu to 11. Done. Setting geom_fluid (mixture) ... Done. Setting intlet (mixture) ... Done. Setting wall-geom_fluid (mixture) ... Done. Setting interior-geom_fluid (mixture) ... Done. Setting outlet (mixture) ... Done. Setting moving (mixture) ... Done. Setting facesize (mixture) ... Done. Setting facesize1 (mixture) ... Done. Setting gudingjiechu (mixture) ... Done. parallel, dynamic zones, moving Done. Preparing mesh for display... Done. Warning: The current graphics driver is inadequate for displaying mesh with material rendering. Any mesh objects with a material specified will not see the material rendered. Select a modern graphics driver such as DX11 or OpenGL2 to use material rendering. Grouping and repartitioning the fluid cell zones to be smoothed... >> 24 Stored Partitions: P Cells I-Cells Cell Ratio Faces I-Faces Face Ratio Neighbors Load 0 108210 3786 0.035 244014 4048 0.017 9 1 1 108371 3613 0.033 243111 3898 0.016 11 1 2 108592 2335 0.022 223463 2411 0.011 4 1 3 108357 2231 0.021 223504 2280 0.010 7 1 4 109924 3154 0.029 228769 3993 0.017 3 1 5 108367 2237 0.021 223595 2456 0.011 6 1 6 110688 3378 0.031 230679 4321 0.019 3 1 7 108678 1900 0.017 224617 1946 0.009 5 1 8 109206 4614 0.042 227935 5790 0.025 8 1 9 108432 2137 0.020 223527 2272 0.010 6 1 10 108240 3996 0.037 235330 4348 0.018 8 1 11 108348 1925 0.018 223279 1975 0.009 5 1 12 109197 3987 0.037 227806 4983 0.022 10 1 13 108466 2022 0.019 223457 2187 0.010 5 1 14 108570 2492 0.023 223401 2605 0.012 7 1 15 108206 6420 0.059 237243 6866 0.029 20 1 16 108596 2496 0.023 223334 2630 0.012 6 1 17 108403 2648 0.024 224280 2876 0.013 8 1 18 108416 2020 0.019 223493 2128 0.010 5 1 19 108722 2101 0.019 223105 2198 0.010 8 1 20 108306 2059 0.019 223196 2103 0.009 6 1 21 108327 1976 0.018 223415 2018 0.009 5 1 22 108430 4547 0.042 240563 4994 0.021 12 1 23 108664 3037 0.028 223233 3164 0.014 9 1 ---------------------------------------------------------------------- Collective Partition Statistics: Minimum Maximum Total ---------------------------------------------------------------------- Cell count 108206 110688 2607716 Mean cell count deviation -0.4% 1.9% Partition boundary cell count 1900 6420 71111 Partition boundary cell count ratio 1.7% 5.9% 2.7% Face count 223105 244014 5429104 Mean face count deviation -2.1% 7.1% Partition boundary face count 1946 6866 39245 Partition boundary face count ratio 0.9% 2.9% 0.7% Partition neighbor count 3 20 ---------------------------------------------------------------------- Partition Method Metis Stored Partition Count 24 Done. 192 partition interfaces of the 101388 cells aspect ratio > 5 2528984 groups for partitioning (including overlaps) Merging groups across partitions: 1 741 2 30 3 0 Partition 2528790 groups out of 2607716 cells Grouping and repartitioning the rest of fluid cell zones (if any)... Migrating partitions to compute-nodes. >> 24 Active Partitions: P Cells I-Cells Cell Ratio Faces I-Faces Face Ratio Neighbors Load Ext Cells 0 108210 3786 0.035 244014 4048 0.017 9 1 3918 1 108371 3613 0.033 243111 3898 0.016 11 1 3822 2 108592 2335 0.022 223463 2411 0.011 4 1 2295 3 108357 2231 0.021 223504 2280 0.010 7 1 2123 4 109924 3154 0.029 228769 3993 0.017 3 1 3086 5 108367 2237 0.021 223595 2456 0.011 6 1 2421 6 110688 3378 0.031 230679 4321 0.019 3 1 3434 7 108678 1900 0.017 224617 1946 0.009 5 1 1812 8 109206 4614 0.042 227935 5790 0.025 8 1 4652 9 108432 2137 0.020 223527 2272 0.010 6 1 2199 10 108240 3996 0.037 235330 4348 0.018 8 1 4223 11 108348 1925 0.018 223279 1975 0.009 5 1 1854 12 109197 3987 0.037 227806 4983 0.022 10 1 3956 13 108466 2022 0.019 223457 2187 0.010 5 1 2150 14 108570 2492 0.023 223401 2605 0.012 7 1 2474 15 108206 6420 0.059 237243 6866 0.029 20 1 6452 16 108596 2496 0.023 223334 2630 0.012 6 1 2472 17 108403 2648 0.024 224280 2876 0.013 8 1 2834 18 108416 2020 0.019 223493 2128 0.010 5 1 2037 19 108722 2101 0.019 223105 2198 0.010 8 1 2077 20 108306 2059 0.019 223196 2103 0.009 6 1 1955 21 108327 1976 0.018 223415 2018 0.009 5 1 1890 22 108430 4547 0.042 240563 4994 0.021 12 1 4906 23 108664 3037 0.028 223233 3164 0.014 9 1 3009 ---------------------------------------------------------------------- Collective Partition Statistics: Minimum Maximum Total ---------------------------------------------------------------------- Cell count 108206 110688 2607716 Mean cell count deviation -0.4% 1.9% Partition boundary cell count 1900 6420 71111 Partition boundary cell count ratio 1.7% 5.9% 2.7% Face count 223105 244014 5429104 Mean face count deviation -2.1% 7.1% Partition boundary face count 1946 6866 39245 Partition boundary face count ratio 0.9% 2.9% 0.7% Partition neighbor count 3 20 ---------------------------------------------------------------------- Partition Method Metis Stored Partition Count 24 Done. Setting Post Processing and Surfaces information ... Done. Reading "\"| gunzip -c \\"G:\10.30\wj_files\dp0\FFF\Fluent\FFF.1-2-00000.dat.gz\\"\""... Parallel variables... Done. Writing "| gzip -2cf > FFF.1-2-00000.cas.gz"... Writing temporary file C:\\Users\\PC\\AppData\\Local\\Temp\\flntgz-243642 ... 2607716 mixed cells, zone 3, binary. 2607716 cell partition ids, zone 3, 24 partitions, binary. 213025 triangular wall faces, zone 1, binary. 5160670 mixed interior faces, zone 2, binary. 141 triangular pressure-inlet faces, zone 6, binary. 114 triangular pressure-outlet faces, zone 7, binary. 31782 triangular wall faces, zone 8, binary. 6258 triangular wall faces, zone 9, binary. 14808 triangular wall faces, zone 10, binary. 2306 triangular wall faces, zone 11, binary. 556980 nodes, binary. 556980 node flags, binary. Done. Writing "| gzip -2cf > FFF.1-2-00000.dat.gz"... Writing temporary file C:\\Users\\PC\\AppData\\Local\\Temp\\flntgz-243643 ... Done. Error : Invalid request method GetNodeData for variable force Deleting Client...done Shutting down Server...done Error calling ResultData.GetNodeData: Performance Timer for 0 iterations on 24 compute nodes Average wall-clock time per iteration: 0.000 sec Global reductions per iteration: 0 ops Global reductions time per iteration: 0.000 sec (0.0%) Message count per iteration: 0 messages Data transfer per iteration: 0.000 MB LE solves per iteration: 0 solves LE wall-clock time per iteration: 0.000 sec (0.0%) LE global solves per iteration: 0 solves LE global wall-clock time per iteration: 0.000 sec (0.0%) LE global matrix maximum size: 0 AMG cycles per iteration: 0.000 cycles Relaxation sweeps per iteration: 0 sweeps Relaxation exchanges per iteration: 0 exchanges LE early protections (stall) per iteration: 0.000 times LE early protections (divergence) per iteration: 0.000 times Total SVARS touched: 375 Total wall-clock time: 0.000 sec Transcript Stop Time: 21:13:11, 01 Nov 2025 й ׼ʱ Total Transcript Time: 2 Minute 16 Second. . 什么问题
最新发布
11-02
<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <!-- Copyright (c) 2016-2020, The Linux Foundation. All rights reserved Not a Contribution. --> <!-- Copyright (C) 2015 The Android Open Source Project Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. --> <!-- Changes from Qualcomm Innovation Center are provided under the following license: Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted (subject to the limitations in the disclaimer below) provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of Qualcomm Innovation Center, Inc. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. NO EXPRESS OR IMPLIED LICENSES TO ANY PARTY'S PATENT RIGHTS ARE GRANTED BY THIS LICENSE. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. --> <audioPolicyConfiguration version="7.0" xmlns:xi="http://www.w3.org/2001/XInclude"> <!-- version section contains a “version” tag in the form “major.minor” e.g version=”1.0” --> <!-- Global configuration Decalaration --> <globalConfiguration speaker_drc_enabled="true" call_screen_mode_supported="true"/> <!-- Modules section: There is one section per audio HW module present on the platform. Each module section will contains two mandatory tags for audio HAL “halVersion” and “name”. The module names are the same as in current .conf file: “primary”, “A2DP”, “remote_submix”, “USB” Each module will contain the following sections: “devicePorts”: a list of device descriptors for all input and output devices accessible via this module. This contains both permanently attached devices and removable devices. “mixPorts”: listing all output and input streams exposed by the audio HAL “routes”: list of possible connections between input and output devices or between stream and devices. "route": is defined by an attribute: -"type": <mux|mix> means all sources are mutual exclusive (mux) or can be mixed (mix) -"sink": the sink involved in this route -"sources": all the sources than can be connected to the sink via vis route “attachedDevices”: permanently attached devices. The attachedDevices section is a list of devices names. The names correspond to device names defined in <devicePorts> section. “defaultOutputDevice”: device to be used by default when no policy rule applies --> <modules> <!-- Primary Audio HAL is now hosted in audio_module_config_primary --> <!-- A2DP Audio HAL --> <!-- #ifndef OPLUS_BUG_STABILITY dongchuancheng@MULTIMEDIA.AUDIOSERVER.FRAMEWORK, 2022/09/29, disalbe unused a2dp module for qcom split bluetooth arch. <module name="a2dp" halVersion="2.0"> <mixPorts> <mixPort name="a2dp input" role="sink"> <profile name="" format="AUDIO_FORMAT_PCM_16_BIT" samplingRates="44100 48000" channelMasks="AUDIO_CHANNEL_IN_MONO AUDIO_CHANNEL_IN_STEREO"/> </mixPort> </mixPorts> <devicePorts> <devicePort tagName="BT A2DP In" type="AUDIO_DEVICE_IN_BLUETOOTH_A2DP" role="source"> <profile name="" format="AUDIO_FORMAT_PCM_16_BIT" samplingRates="44100 48000" channelMasks="AUDIO_CHANNEL_IN_MONO AUDIO_CHANNEL_IN_STEREO"/> </devicePort> </devicePorts> <routes> <route type="mix" sink="a2dp input" sources="BT A2DP In"/> </routes> </module> #endif OPLUS_BUG_STABILITY --> <!-- #ifndef OPLUS_FEATURE_BTAUDIO_LHDC //Yuepeifeng@TECH.CONN.BT.A2DP.36081 2020/03/29 for support LHDC codec--> <module name="bluetooth_qti" halVersion="2.0"> <mixPorts> <mixPort name="a2dp_lhdc output" role="source" flags="AUDIO_OUTPUT_FLAG_SPATIALIZER"> <profile name="" format="AUDIO_FORMAT_PCM_16_BIT" samplingRates="44100 48000 96000" channelMasks="AUDIO_CHANNEL_OUT_STEREO AUDIO_CHANNEL_OUT_MONO"/> <profile name="" format="AUDIO_FORMAT_PCM_24_BIT_PACKED" samplingRates="44100 48000 96000" channelMasks="AUDIO_CHANNEL_OUT_STEREO AUDIO_CHANNEL_OUT_MONO"/> </mixPort> <!-- #ifndef OPLUS_FEATURE_BTAUDIO_AID //fred.li@MULTIMEDIA.AUDIOSERVER.POLICY.1723426 2021/06/22 add for Hearing AIDs Audio Ports--> <mixPort name="hearing aid output" role="source"> <profile name="" format="AUDIO_FORMAT_PCM_16_BIT" samplingRates="24000 16000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/> </mixPort> <!--endif OPLUS_FEATURE_BTAUDIO_AID--> </mixPorts> <devicePorts> <!-- A2DP Audio Ports --> <devicePort tagName="BT A2DP Out" type="AUDIO_DEVICE_OUT_BLUETOOTH_A2DP" role="sink" encodedFormats="AUDIO_FORMAT_LHDC AUDIO_FORMAT_LHDC_LL"> <profile name="" format="AUDIO_FORMAT_PCM_16_BIT" samplingRates="44100 48000 96000" channelMasks="AUDIO_CHANNEL_OUT_STEREO AUDIO_CHANNEL_OUT_MONO"/> <profile name="" format="AUDIO_FORMAT_PCM_24_BIT_PACKED" samplingRates="44100 48000 96000" channelMasks="AUDIO_CHANNEL_OUT_STEREO AUDIO_CHANNEL_OUT_MONO"/> </devicePort> <devicePort tagName="BT A2DP Headphones" type="AUDIO_DEVICE_OUT_BLUETOOTH_A2DP_HEADPHONES" role="sink" encodedFormats="AUDIO_FORMAT_LHDC AUDIO_FORMAT_LHDC_LL"> <profile name="" format="AUDIO_FORMAT_PCM_16_BIT" samplingRates="44100 48000 96000" channelMasks="AUDIO_CHANNEL_OUT_STEREO AUDIO_CHANNEL_OUT_MONO"/> <profile name="" format="AUDIO_FORMAT_PCM_24_BIT_PACKED" samplingRates="44100 48000 96000" channelMasks="AUDIO_CHANNEL_OUT_STEREO AUDIO_CHANNEL_OUT_MONO"/> </devicePort> <devicePort tagName="BT A2DP Speaker" type="AUDIO_DEVICE_OUT_BLUETOOTH_A2DP_SPEAKER" role="sink" encodedFormats="AUDIO_FORMAT_LHDC AUDIO_FORMAT_LHDC_LL"> <profile name="" format="AUDIO_FORMAT_PCM_16_BIT" samplingRates="44100 48000 96000" channelMasks="AUDIO_CHANNEL_OUT_STEREO AUDIO_CHANNEL_OUT_MONO"/> <profile name="" format="AUDIO_FORMAT_PCM_24_BIT_PACKED" samplingRates="44100 48000 96000" channelMasks="AUDIO_CHANNEL_OUT_STEREO AUDIO_CHANNEL_OUT_MONO"/> </devicePort> <!-- #ifndef OPLUS_FEATURE_BTAUDIO_AID //fred.li@MULTIMEDIA.AUDIOSERVER.POLICY.1723426 2021/06/22 add for Hearing AIDs Audio Ports--> <devicePort tagName="BT Hearing Aid Out" type="AUDIO_DEVICE_OUT_HEARING_AID" role="sink"/> <!--endif OPLUS_FEATURE_BTAUDIO_AID--> </devicePorts> <routes> <route type="mix" sink="BT A2DP Out" sources="a2dp_lhdc output"/> <route type="mix" sink="BT A2DP Headphones" sources="a2dp_lhdc output"/> <route type="mix" sink="BT A2DP Speaker" sources="a2dp_lhdc output"/> <!-- #ifndef OPLUS_FEATURE_BTAUDIO_AID fred.li@MULTIMEDIA.AUDIOSERVER.POLICY.1723426 2021/06/22 add for Hearing AIDs Audio Ports--> <route type="mix" sink="BT Hearing Aid Out" sources="hearing aid output"/> <!--endif /* OPLUS_FEATURE_BTAUDIO_AID */ --> </routes> </module> <!--endif OPLUS_FEATURE_BTAUDIO_LHDC--> <!-- Usb Audio HAL --> <module name="usb" halVersion="2.0"> <mixPorts> <mixPort name="usb_accessory output" role="source"> <profile name="" format="AUDIO_FORMAT_PCM_16_BIT" samplingRates="44100" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/> </mixPort> </mixPorts> <devicePorts> <devicePort tagName="USB Host Out" type="AUDIO_DEVICE_OUT_USB_ACCESSORY" role="sink"> <profile name="" format="AUDIO_FORMAT_PCM_16_BIT" samplingRates="44100" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/> </devicePort> </devicePorts> <routes> <route type="mix" sink="USB Host Out" sources="usb_accessory output"/> </routes> </module> <!-- #ifdef OPLUS_FEATURE_BTAUDIO_BINAURAL_RECORD --> <module name="binaural_record" halVersion="2.0"> <mixPorts> <mixPort name="Bluetooth record" role="sink"> <profile name="" format="AUDIO_FORMAT_PCM_16_BIT" samplingRates="44100 48000 96000" channelMasks="AUDIO_CHANNEL_IN_MONO AUDIO_CHANNEL_IN_STEREO"/> <profile name="" format="AUDIO_FORMAT_PCM_24_BIT_PACKED" samplingRates="44100 48000 96000" channelMasks="AUDIO_CHANNEL_IN_MONO AUDIO_CHANNEL_IN_STEREO"/> </mixPort> </mixPorts> <devicePorts> <devicePort tagName="BT Record in" type="AUDIO_DEVICE_IN_PROXY" role="source" address=""> <profile name="" format="AUDIO_FORMAT_PCM_16_BIT" samplingRates="44100 48000 96000" channelMasks="AUDIO_CHANNEL_IN_MONO AUDIO_CHANNEL_IN_STEREO"/> <profile name="" format="AUDIO_FORMAT_PCM_24_BIT_PACKED" samplingRates="44100 48000 96000" channelMasks="AUDIO_CHANNEL_IN_MONO AUDIO_CHANNEL_IN_STEREO"/> </devicePort> </devicePorts> <routes> <route type="mix" sink="Bluetooth record" sources="BT Record in"/> </routes> </module> <!-- #endif OPLUS_FEATURE_BTAUDIO_BINAURAL_RECORD --> <!-- #ifdef OPLUS_FEATURE_VIRTUAL_AUDIO --> <!-- ZhangHui@MULTIMEDIA.AUDIOSERVER.BASE, 2021/10/11, Add for virtual audio --> <xi:include href="/odm/etc/virtual_audio_policy_configuration.xml"> <xi:fallback></xi:fallback> </xi:include> <!-- #endif OPLUS_FEATURE_VIRTUAL_AUDIO --> <!-- Remote Submix Audio HAL --> <xi:include href="/vendor/etc/r_submix_audio_policy_configuration.xml"/> <!-- Bluetooth Audio HAL for hearing aid --> <!-- #ifndef OPLUS_BUG_STABILITY dongchuancheng@MULTIMEDIA.AUDIOSERVER.FRAMEWORK, 2022/09/20, disable unused module <xi:include href="/vendor/etc/bluetooth_qti_hearing_aid_audio_policy_configuration.xml"/> #endif /* OPLUS_BUG_STABILITY */ --> </modules> <!-- End of Modules section --> <!-- Volume section --> <!-- #ifndef OPLUS_BUG_STABILITY YeWenliang@MULTIMEDIA.AUDIODRIVER.HAL 2022/09/29 <xi:include href="/vendor/etc/audio_policy_volumes.xml"/> <xi:include href="/vendor/etc/default_volume_tables.xml"/> #else /* OPLUS_BUG_STABILITY */--> <xi:include href="audio_policy_volumes.xml"/> <xi:include href="default_volume_tables.xml"/> <!-- #endif /* OPLUS_BUG_STABILITY */ --> <!-- End of Volume section --> </audioPolicyConfiguration> 以上文件路径:/mnt/vendor/my_product/etc/audio_policy_configuration.xml 一加13 Coloros15,安卓版本15,修改该文件,绕过安卓音频SRC实现系统全局自适应采样率(Dynamic sampling rates)、自适应位深(Bit_perfect)(保持音频文件原始位深,16bit文件不升级位深)、禁用升频和重采样,关闭所有音频音效(effect)以及影响音频质量无损输出的一切音频处理,最大程度上抑制并降低音频抖动(jitter)(最大化优化时钟管理和同步)、最大程度降低音频失真和噪声以及电源纹波和噪声,以输出输入最干净无污染最高质量的HIFI无损原始音频信号直出,输出修改过的完整文件
08-12
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值