formatting code using astyle

Origin commit data
------------------
Branch: master
Commit: bc17c13de4
Author: vanhofen <vanhofen@gmx.de>
Date: 2021-05-17 (Mon, 17 May 2021)

Origin message was:
------------------
- formatting code using astyle

------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
vanhofen
2021-05-17 23:47:39 +02:00
parent 7335985023
commit f54b0e7bec
161 changed files with 13025 additions and 11357 deletions

View File

@@ -231,7 +231,7 @@ static int Write(Context_t *context, void *_out)
audio = !strcmp("audio", out->type);
linuxdvb_printf(20, "DataLength=%u PrivateLength=%u Pts=%"PRIu64" FrameRate=%d\n",
out->len, out->extralen, out->pts, out->frameRate);
out->len, out->extralen, out->pts, out->frameRate);
linuxdvb_printf(20, "v%d a%d\n", video, audio);
if (video)

View File

@@ -821,7 +821,7 @@ static int Write(Context_t *context, void *_out)
audio = !strcmp("audio", out->type);
linuxdvb_printf(20, "DataLength=%u PrivateLength=%u Pts=%" PRIu64 " FrameRate=%d\n",
out->len, out->extralen, out->pts, out->frameRate);
out->len, out->extralen, out->pts, out->frameRate);
linuxdvb_printf(20, "v%d a%d\n", video, audio);
if (video)

View File

@@ -963,7 +963,7 @@ static int Write(void *_context, void *_out)
audio = !strcmp("audio", out->type);
linuxdvb_printf(20, "DataLength=%u PrivateLength=%u Pts=%llu FrameRate=%f\n",
out->len, out->extralen, out->pts, out->frameRate);
out->len, out->extralen, out->pts, out->frameRate);
linuxdvb_printf(20, "v%d a%d\n", video, audio);
if (video)

View File

@@ -138,7 +138,7 @@ stb_type_t GetSTBType()
type = STB_DREAMBOX;
}
else if (access("/proc/stb/info/vumodel", F_OK) != -1 &&
access("/proc/stb/info/boxtype", F_OK) == -1)
access("/proc/stb/info/boxtype", F_OK) == -1)
{
// some STB like Octagon SF4008 has also /proc/stb/info/vumodel
// but VU PLUS does not have /proc/stb/info/boxtype

View File

@@ -169,7 +169,7 @@ static int _writeData(WriterAVCallData_t *call, int type)
else // check LOAS header
{
if (!(call->len > 2 && call->data[0] == 0x56 && (call->data[1] >> 4) == 0xe &&
((uint32_t)(AV_RB16(call->data + 1) & 0x1FFF) + 3) == call->len))
((uint32_t)(AV_RB16(call->data + 1) & 0x1FFF) + 3) == call->len))
{
aac_err("parsing Data with wrong latm header. ignoring...\n");
return 0;
@@ -213,7 +213,7 @@ static int writeDataADTS(WriterAVCallData_t *call)
}
if ((call->private_data && 0 == strncmp("ADTS", (const char *)call->private_data, call->private_size)) ||
HasADTSHeader(call->data, call->len))
HasADTSHeader(call->data, call->len))
{
//printf("%hhx %hhx %hhx %hhx %hhx %hhx %hhx %hhx\n", call->data[0], call->data[1], call->data[2], call->data[3], call->data[4], call->data[5], call->data[6], call->data[7]);
return _writeData(call, 0);

View File

@@ -132,11 +132,11 @@ static int writeData(WriterAVCallData_t *call)
data += 38;
data[0] = B_GET_BITS(width, 11, 4);
data[1] = B_SET_BITS("width [3..0]", B_GET_BITS(width, 3, 0), 7, 4) |
B_SET_BITS("'10'", 0x02, 3, 2) |
B_SET_BITS("height [11..10]", B_GET_BITS(height, 11, 10), 1, 0);
B_SET_BITS("'10'", 0x02, 3, 2) |
B_SET_BITS("height [11..10]", B_GET_BITS(height, 11, 10), 1, 0);
data[2] = B_GET_BITS(height, 9, 2);
data[3] = B_SET_BITS("height [1.0]", B_GET_BITS(height, 1, 0), 7, 6) |
B_SET_BITS("'100000'", 0x20, 5, 0);
B_SET_BITS("'100000'", 0x20, 5, 0);
iov[ic].iov_base = brcm_divx311_sequence_header;
iov[ic++].iov_len = sizeof(brcm_divx311_sequence_header);

View File

@@ -335,8 +335,8 @@ static int writeData(WriterAVCallData_t *call)
/* AnnexA */
if (!avc3 && ((1 < call->private_size && 0 == call->private_data[0]) ||
((call->len > 3) && ((call->data[0] == 0x00 && call->data[1] == 0x00 && call->data[2] == 0x00 && call->data[3] == 0x01) ||
(call->data[0] == 0xff && call->data[1] == 0xff && call->data[2] == 0xff && call->data[3] == 0xff)))))
((call->len > 3) && ((call->data[0] == 0x00 && call->data[1] == 0x00 && call->data[2] == 0x00 && call->data[3] == 0x01) ||
(call->data[0] == 0xff && call->data[1] == 0xff && call->data[2] == 0xff && call->data[3] == 0xff)))))
{
uint32_t i = 0;
uint8_t InsertPrivData = !sps_pps_in_stream;

View File

@@ -137,7 +137,7 @@ static int writeData(WriterAVCallData_t *call)
case AV_CODEC_ID_PCM_S16LE:
case AV_CODEC_ID_PCM_U16LE:
LE = 1;
// fall through
// fall through
case AV_CODEC_ID_PCM_S16BE:
case AV_CODEC_ID_PCM_U16BE:
width = depth = 16;
@@ -145,7 +145,7 @@ static int writeData(WriterAVCallData_t *call)
case AV_CODEC_ID_PCM_S24LE:
case AV_CODEC_ID_PCM_U24LE:
LE = 1;
// fall through
// fall through
case AV_CODEC_ID_PCM_S24BE:
case AV_CODEC_ID_PCM_U24BE:
width = depth = 24;
@@ -153,7 +153,7 @@ static int writeData(WriterAVCallData_t *call)
case AV_CODEC_ID_PCM_S32LE:
case AV_CODEC_ID_PCM_U32LE:
LE = 1;
// fall through
// fall through
case AV_CODEC_ID_PCM_S32BE:
case AV_CODEC_ID_PCM_U32BE:
width = depth = 32;

View File

@@ -144,8 +144,8 @@ ssize_t WriteWithRetry(Context_t *context, int pipefd, int fd, void *pDVBMtx __a
//if (retval == 0)
//{
// //printf("RETURN FROM SELECT DUE TO TIMEOUT\n");
// continue;
// //printf("RETURN FROM SELECT DUE TO TIMEOUT\n");
// continue;
//}
if (FD_ISSET(pipefd, &rfds))

View File

@@ -168,7 +168,7 @@ static int _writeData(void *_call, int type)
else // check LOAS header
{
if (!(call->len > 2 && call->data[0] == 0x56 && (call->data[1] >> 4) == 0xe &&
(AV_RB16(call->data + 1) & 0x1FFF) + 3 == call->len))
(AV_RB16(call->data + 1) & 0x1FFF) + 3 == call->len))
{
aac_err("parsing Data with wrong latm header. ignoring...\n");
return 0;
@@ -214,7 +214,7 @@ static int writeDataADTS(void *_call)
}
if ((call->private_data && 0 == strncmp("ADTS", call->private_data, call->private_size)) ||
HasADTSHeader(call->data, call->len))
HasADTSHeader(call->data, call->len))
{
return _writeData(_call, 0);
}

View File

@@ -237,8 +237,8 @@ static int32_t writeData(void *_call)
/* AnnexA */
if (!avc3 && ((1 < call->private_size && 0 == call->private_data[0]) ||
(call->len > 3) && ((call->data[0] == 0x00 && call->data[1] == 0x00 && call->data[2] == 0x00 && call->data[3] == 0x01) ||
(call->data[0] == 0xff && call->data[1] == 0xff && call->data[2] == 0xff && call->data[3] == 0xff))))
(call->len > 3) && ((call->data[0] == 0x00 && call->data[1] == 0x00 && call->data[2] == 0x00 && call->data[3] == 0x01) ||
(call->data[0] == 0xff && call->data[1] == 0xff && call->data[2] == 0xff && call->data[3] == 0xff))))
{
uint32_t PacketLength = 0;
uint32_t FakeStartCode = /*(call->Version << 8) | */PES_VERSION_FAKE_START_CODE;
@@ -440,7 +440,7 @@ static int32_t writeData(void *_call)
if (NalStart + NalLength > SampleSize)
{
h264_printf(20, "nal length past end of buffer - size %u frame offset %u left %u\n",
NalLength, NalStart, SampleSize - NalStart);
NalLength, NalStart, SampleSize - NalStart);
NalStart = SampleSize;
}

View File

@@ -106,7 +106,7 @@ static int writeData(void *_call)
while (Position < call->len)
{
int32_t PacketLength = (call->len - Position) <= MAX_PES_PACKET_SIZE ?
(call->len - Position) : MAX_PES_PACKET_SIZE;
(call->len - Position) : MAX_PES_PACKET_SIZE;
int32_t Remaining = call->len - Position - PacketLength;

View File

@@ -97,11 +97,11 @@ static uint32_t breakBufferFillSize = 0;
static int32_t prepareClipPlay(int32_t uNoOfChannels, int32_t uSampleRate, int32_t uBitsPerSample, uint8_t bLittleEndian __attribute__((unused)))
{
printf("rate: %d ch: %d bits: %d (%d bps)\n",
uSampleRate/*Format->dwSamplesPerSec*/,
uNoOfChannels/*Format->wChannels*/,
uBitsPerSample/*Format->wBitsPerSample*/,
(uBitsPerSample/*Format->wBitsPerSample*/ / 8)
);
uSampleRate/*Format->dwSamplesPerSec*/,
uNoOfChannels/*Format->wChannels*/,
uBitsPerSample/*Format->wBitsPerSample*/,
(uBitsPerSample/*Format->wBitsPerSample*/ / 8)
);
SubFrameLen = 0;
SubFramesPerPES = 0;

View File

@@ -197,7 +197,7 @@ static int writeData(void *_call)
while (Position < call->len)
{
int32_t PacketLength = (call->len - Position) <= MAX_PES_PACKET_SIZE ?
(call->len - Position) : MAX_PES_PACKET_SIZE;
(call->len - Position) : MAX_PES_PACKET_SIZE;
int32_t Remaining = call->len - Position - PacketLength;

View File

@@ -134,7 +134,7 @@ static int writeData(void *_call)
wmv_printf(10, "Got Private Size %d\n", call->private_size);
memcpy(private_data.privateData, call->private_data,
call->private_size > WMV3_PRIVATE_DATA_LENGTH ? WMV3_PRIVATE_DATA_LENGTH : call->private_size);
call->private_size > WMV3_PRIVATE_DATA_LENGTH ? WMV3_PRIVATE_DATA_LENGTH : call->private_size);
private_data.width = call->Width;
private_data.height = call->Height;
@@ -196,7 +196,7 @@ static int writeData(void *_call)
while (Position < call->len)
{
int PacketLength = (call->len - Position) <= MAX_PES_PACKET_SIZE ?
(call->len - Position) : MAX_PES_PACKET_SIZE;
(call->len - Position) : MAX_PES_PACKET_SIZE;
int Remaining = call->len - Position - PacketLength;
@@ -214,7 +214,7 @@ static int writeData(void *_call)
PrivateHeaderLength = InsertVideoPrivateDataHeader(&PesHeader[HeaderLength], call->len);
/* Update PesLength */
PesLength = PesHeader[PES_LENGTH_BYTE_0] +
(PesHeader[PES_LENGTH_BYTE_1] << 8) + PrivateHeaderLength;
(PesHeader[PES_LENGTH_BYTE_1] << 8) + PrivateHeaderLength;
PesHeader[PES_LENGTH_BYTE_0] = PesLength & 0xff;
PesHeader[PES_LENGTH_BYTE_1] = (PesLength >> 8) & 0xff;
PesHeader[PES_HEADER_DATA_LENGTH_BYTE] += PrivateHeaderLength;

View File

@@ -44,7 +44,7 @@
static short debug_level = 0;
#define writer_printf(level, x...) do { \
if (debug_level >= level) printf(x); } while (0)
if (debug_level >= level) printf(x); } while (0)
#else
#define writer_printf(level, x...)
#endif