History

swscale/output: fix some code indentations

Linjie Fu committed 7 years ago

Commit ef134261 parent 722fd461 file · +35 −35Browse files

Unified · Split

libswscale/output.c+35−35
@@ -630,28 +630,28 @@ yuv2mono_2_c_template(SwsContext *c, const int16_t *buf[2], · 629 unmodified lines
630630 }
631631 c->dither_error[0][i] = err;
632632 } else {
633− for (i = 0; i < dstW; i += 8) {
634− int Y, acc = 0;
635−
636− Y = (buf0[i + 0] * yalpha1 + buf1[i + 0] * yalpha) >> 19;
637− accumulate_bit(acc, Y + d128[0]);
638− Y = (buf0[i + 1] * yalpha1 + buf1[i + 1] * yalpha) >> 19;
639− accumulate_bit(acc, Y + d128[1]);
640− Y = (buf0[i + 2] * yalpha1 + buf1[i + 2] * yalpha) >> 19;
641− accumulate_bit(acc, Y + d128[2]);
642− Y = (buf0[i + 3] * yalpha1 + buf1[i + 3] * yalpha) >> 19;
643− accumulate_bit(acc, Y + d128[3]);
644− Y = (buf0[i + 4] * yalpha1 + buf1[i + 4] * yalpha) >> 19;
645− accumulate_bit(acc, Y + d128[4]);
646− Y = (buf0[i + 5] * yalpha1 + buf1[i + 5] * yalpha) >> 19;
647− accumulate_bit(acc, Y + d128[5]);
648− Y = (buf0[i + 6] * yalpha1 + buf1[i + 6] * yalpha) >> 19;
649− accumulate_bit(acc, Y + d128[6]);
650− Y = (buf0[i + 7] * yalpha1 + buf1[i + 7] * yalpha) >> 19;
651− accumulate_bit(acc, Y + d128[7]);
652−
653− output_pixel(*dest++, acc);
654− }
633+ for (i = 0; i < dstW; i += 8) {
634+ int Y, acc = 0;
635+
636+ Y = (buf0[i + 0] * yalpha1 + buf1[i + 0] * yalpha) >> 19;
637+ accumulate_bit(acc, Y + d128[0]);
638+ Y = (buf0[i + 1] * yalpha1 + buf1[i + 1] * yalpha) >> 19;
639+ accumulate_bit(acc, Y + d128[1]);
640+ Y = (buf0[i + 2] * yalpha1 + buf1[i + 2] * yalpha) >> 19;
641+ accumulate_bit(acc, Y + d128[2]);
642+ Y = (buf0[i + 3] * yalpha1 + buf1[i + 3] * yalpha) >> 19;
643+ accumulate_bit(acc, Y + d128[3]);
644+ Y = (buf0[i + 4] * yalpha1 + buf1[i + 4] * yalpha) >> 19;
645+ accumulate_bit(acc, Y + d128[4]);
646+ Y = (buf0[i + 5] * yalpha1 + buf1[i + 5] * yalpha) >> 19;
647+ accumulate_bit(acc, Y + d128[5]);
648+ Y = (buf0[i + 6] * yalpha1 + buf1[i + 6] * yalpha) >> 19;
649+ accumulate_bit(acc, Y + d128[6]);
650+ Y = (buf0[i + 7] * yalpha1 + buf1[i + 7] * yalpha) >> 19;
651+ accumulate_bit(acc, Y + d128[7]);
652+
653+ output_pixel(*dest++, acc);
654+ }
655655 }
656656 }
657657
@@ -687,19 +687,19 @@ yuv2mono_1_c_template(SwsContext *c, const int16_t *buf0, · 29 unmodified lines
687687 }
688688 c->dither_error[0][i] = err;
689689 } else {
690− for (i = 0; i < dstW; i += 8) {
691− int acc = 0;
692− accumulate_bit(acc, ((buf0[i + 0] + 64) >> 7) + d128[0]);
693− accumulate_bit(acc, ((buf0[i + 1] + 64) >> 7) + d128[1]);
694− accumulate_bit(acc, ((buf0[i + 2] + 64) >> 7) + d128[2]);
695− accumulate_bit(acc, ((buf0[i + 3] + 64) >> 7) + d128[3]);
696− accumulate_bit(acc, ((buf0[i + 4] + 64) >> 7) + d128[4]);
697− accumulate_bit(acc, ((buf0[i + 5] + 64) >> 7) + d128[5]);
698− accumulate_bit(acc, ((buf0[i + 6] + 64) >> 7) + d128[6]);
699− accumulate_bit(acc, ((buf0[i + 7] + 64) >> 7) + d128[7]);
700−
701− output_pixel(*dest++, acc);
702− }
690+ for (i = 0; i < dstW; i += 8) {
691+ int acc = 0;
692+ accumulate_bit(acc, ((buf0[i + 0] + 64) >> 7) + d128[0]);
693+ accumulate_bit(acc, ((buf0[i + 1] + 64) >> 7) + d128[1]);
694+ accumulate_bit(acc, ((buf0[i + 2] + 64) >> 7) + d128[2]);
695+ accumulate_bit(acc, ((buf0[i + 3] + 64) >> 7) + d128[3]);
696+ accumulate_bit(acc, ((buf0[i + 4] + 64) >> 7) + d128[4]);
697+ accumulate_bit(acc, ((buf0[i + 5] + 64) >> 7) + d128[5]);
698+ accumulate_bit(acc, ((buf0[i + 6] + 64) >> 7) + d128[6]);
699+ accumulate_bit(acc, ((buf0[i + 7] + 64) >> 7) + d128[7]);
700+
701+ output_pixel(*dest++, acc);
702+ }
703703 }
704704 }
705705

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t