@@ -48,7 +48,7 @@ static void CheckForTerminatedRealtimeProcesses(
48
48
)
49
49
{
50
50
LARGE_INTEGER performanceCounter;
51
- PhQueryPerformanceCounter (&performanceCounter, NULL );
51
+ PhQueryPerformanceCounter (&performanceCounter, nullptr );
52
52
terminatedProcesses->emplace_back (processId, performanceCounter.QuadPart );
53
53
54
54
PhClearReference (reinterpret_cast <PVOID*>(&processInfo->ProcessItem ));
@@ -347,14 +347,14 @@ VOID PresentMonUpdateProcessStats(
347
347
348
348
EtAddGpuFrameToHashTable (
349
349
ProcessId,
350
- frameLatency,
351
- framesPerSecond,
352
- displayLatency,
353
- displayFramesPerSecond,
354
- msBetweenPresents,
355
- msInPresentApi,
356
- msUntilRenderComplete,
357
- msUntilDisplayed,
350
+ static_cast <FLOAT>( frameLatency) ,
351
+ static_cast <FLOAT>( framesPerSecond) ,
352
+ static_cast <FLOAT>( displayLatency) ,
353
+ static_cast <FLOAT>( displayFramesPerSecond) ,
354
+ static_cast <FLOAT>( msBetweenPresents) ,
355
+ static_cast <FLOAT>( msInPresentApi) ,
356
+ static_cast <FLOAT>( msUntilRenderComplete) ,
357
+ static_cast <FLOAT>( msUntilDisplayed) ,
358
358
runtime,
359
359
presentMode
360
360
);
@@ -427,7 +427,7 @@ VOID StartOutputThread(
427
427
{
428
428
HANDLE threadHandle;
429
429
430
- if (NT_SUCCESS (PhCreateThreadEx (&threadHandle, PresentMonOutputThread, NULL )))
430
+ if (NT_SUCCESS (PhCreateThreadEx (&threadHandle, PresentMonOutputThread, nullptr )))
431
431
{
432
432
PhSetThreadName (threadHandle, L" FpsEtwOutputThread" );
433
433
NtClose (threadHandle);
@@ -442,7 +442,7 @@ VOID StopOutputThread(
442
442
)
443
443
{
444
444
InterlockedExchange (&QuitOutputThread, 1 );
445
- // NtWaitForSingleObject(OutputThreadHandle, FALSE, NULL );
445
+ // NtWaitForSingleObject(OutputThreadHandle, FALSE, nullptr );
446
446
}
447
447
448
448
static NTSTATUS PresentMonTraceThread (
@@ -454,7 +454,7 @@ static NTSTATUS PresentMonTraceThread(
454
454
455
455
while (TRUE )
456
456
{
457
- while (!QuitOutputThread && (result = ProcessTrace (&traceHandle, 1 , NULL , NULL )) == ERROR_SUCCESS)
457
+ while (!QuitOutputThread && (result = ProcessTrace (&traceHandle, 1 , nullptr , nullptr )) == ERROR_SUCCESS)
458
458
NOTHING;
459
459
460
460
if (QuitOutputThread)
@@ -480,7 +480,7 @@ VOID StartConsumerThread(
480
480
{
481
481
HANDLE threadHandle;
482
482
483
- if (NT_SUCCESS (PhCreateThreadEx (&threadHandle, PresentMonTraceThread, ( PVOID) traceHandle)))
483
+ if (NT_SUCCESS (PhCreateThreadEx (&threadHandle, PresentMonTraceThread, reinterpret_cast < PVOID>( traceHandle) )))
484
484
{
485
485
PhSetThreadName (threadHandle, L" FpsEtwConsumerThread" );
486
486
NtClose (threadHandle);
@@ -495,5 +495,5 @@ VOID WaitForConsumerThreadToExit(
495
495
)
496
496
{
497
497
InterlockedExchange (&QuitOutputThread, 1 );
498
- // NtWaitForSingleObject(ConsumerThreadHandle, FALSE, NULL );
498
+ // NtWaitForSingleObject(ConsumerThreadHandle, FALSE, nullptr );
499
499
}
0 commit comments