video_producer_demo: fix comparison warnings
Change-Id: Ibfc8780c55e229190573918a4cf1f119b5e345c6 Reviewed-on: https://review.haiku-os.org/c/haiku/+/4504 Reviewed-by: Franck LeCodeur <[email protected]> Reviewed-by: Jérôme Duval <[email protected]>
This commit is contained in:
@@ -716,7 +716,7 @@ rule ArchitectureSetupWarnings architecture
|
|||||||
EnableWerror src add-ons media media-add-ons usb_vision ;
|
EnableWerror src add-ons media media-add-ons usb_vision ;
|
||||||
# EnableWerror src add-ons media media-add-ons usb_webcam ;
|
# EnableWerror src add-ons media media-add-ons usb_webcam ;
|
||||||
EnableWerror src add-ons media media-add-ons video_mixer ;
|
EnableWerror src add-ons media media-add-ons video_mixer ;
|
||||||
# EnableWerror src add-ons media media-add-ons video_producer_demo ;
|
EnableWerror src add-ons media media-add-ons video_producer_demo ;
|
||||||
EnableWerror src add-ons media media-add-ons videowindow ;
|
EnableWerror src add-ons media media-add-ons videowindow ;
|
||||||
EnableWerror src add-ons media media-add-ons writer ;
|
EnableWerror src add-ons media media-add-ons writer ;
|
||||||
EnableWerror src add-ons media plugins ape_reader ;
|
EnableWerror src add-ons media plugins ape_reader ;
|
||||||
|
|||||||
@@ -440,8 +440,8 @@ VideoProducer::Connect(status_t error, const media_source &source,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
bigtime_t now = system_time();
|
bigtime_t now = system_time();
|
||||||
for (int y = 0; y < (int)fConnectedFormat.display.line_count; y++)
|
for (uint32 y = 0; y < fConnectedFormat.display.line_count; y++)
|
||||||
for (int x = 0; x < (int)fConnectedFormat.display.line_width; x++)
|
for (uint32 x = 0; x < fConnectedFormat.display.line_width; x++)
|
||||||
*(p++) = ((((x+y)^0^x)+f) & 0xff) * (0x01010101 & fColor);
|
*(p++) = ((((x+y)^0^x)+f) & 0xff) * (0x01010101 & fColor);
|
||||||
fProcessingLatency = system_time() - now;
|
fProcessingLatency = system_time() - now;
|
||||||
free(buffer);
|
free(buffer);
|
||||||
@@ -724,8 +724,8 @@ VideoProducer::FrameGenerator()
|
|||||||
if (fColor == 0xff000000) {
|
if (fColor == 0xff000000) {
|
||||||
// display a gray block that moves
|
// display a gray block that moves
|
||||||
uint32 *p = (uint32 *)buffer->Data();
|
uint32 *p = (uint32 *)buffer->Data();
|
||||||
for (int y = 0; y < (int)fConnectedFormat.display.line_count; y++)
|
for (uint32 y = 0; y < fConnectedFormat.display.line_count; y++)
|
||||||
for (int x = 0; x < (int)fConnectedFormat.display.line_width; x++) {
|
for (uint32 x = 0; x < fConnectedFormat.display.line_width; x++) {
|
||||||
if (x > (fFrame & 0xff) && x < (fFrame & 0xff) + 60 && y > 90 && y < 150) {
|
if (x > (fFrame & 0xff) && x < (fFrame & 0xff) + 60 && y > 90 && y < 150) {
|
||||||
*(p++) = 0xff777777;
|
*(p++) = 0xff777777;
|
||||||
} else {
|
} else {
|
||||||
@@ -736,8 +736,8 @@ VideoProducer::FrameGenerator()
|
|||||||
|
|
||||||
/* Fill in a pattern */
|
/* Fill in a pattern */
|
||||||
uint32 *p = (uint32 *)buffer->Data();
|
uint32 *p = (uint32 *)buffer->Data();
|
||||||
for (int y = 0; y < (int)fConnectedFormat.display.line_count; y++)
|
for (uint32 y = 0; y < fConnectedFormat.display.line_count; y++)
|
||||||
for (int x = 0; x < (int)fConnectedFormat.display.line_width; x++)
|
for (uint32 x = 0; x < fConnectedFormat.display.line_width; x++)
|
||||||
*(p++) = ((((x+y)^0^x)+fFrame) & 0xff) * (0x01010101 & fColor);
|
*(p++) = ((((x+y)^0^x)+fFrame) & 0xff) * (0x01010101 & fColor);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user