Skip to content

Commit

Permalink
disabled timers
Browse files Browse the repository at this point in the history
  • Loading branch information
matt-m-o committed Oct 15, 2023
1 parent 70935cd commit ec395c2
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ export class SharpImageProcessingAdapter implements ImageProcessingAdapter {

async resize( input: ImageResizeInput ): Promise< ImageResizeOutput > {

console.time("Sharp.resize");
// console.time("Sharp.resize");

const { imageBuffer, scaling_factor } = input;

Expand All @@ -14,7 +14,7 @@ export class SharpImageProcessingAdapter implements ImageProcessingAdapter {

if ( scaling_factor == 1 ) {

console.timeEnd("Sharp.resize");
// console.timeEnd("Sharp.resize");
return {
resizedImage: imageBuffer,
}
Expand All @@ -27,7 +27,7 @@ export class SharpImageProcessingAdapter implements ImageProcessingAdapter {

if ( !width || !height ) {

console.timeEnd("Sharp.resize");
// console.timeEnd("Sharp.resize");
return {
resizedImage: imageBuffer
};
Expand All @@ -36,7 +36,7 @@ export class SharpImageProcessingAdapter implements ImageProcessingAdapter {
const newWidth = Math.floor( width * scaling_factor );
const newHeight = Math.floor( height * scaling_factor );

console.timeEnd("Sharp.resize");
// console.timeEnd("Sharp.resize");
return {
resizedImage: await sharpInstance.resize( newWidth, newHeight ).toBuffer(),
width: newWidth,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -107,8 +107,8 @@ export class OcrRecognitionController {
}

async recognize( entireScreenImage?: Buffer, runFullScreenImageCheck?: boolean ) {
console.log('');
console.time('controller.recognize');
// console.log('');
// console.time('controller.recognize');

try {
// console.log(activeProfile);
Expand All @@ -122,8 +122,8 @@ export class OcrRecognitionController {
window: this.captureSourceWindow,
});

console.timeEnd('controller.recognize');
console.log('');
// console.timeEnd('controller.recognize');
// console.log('');

this.overlayWindow.webContents.send( 'ocr:result', ocrResultScalable );

Expand Down Expand Up @@ -246,7 +246,7 @@ export class OcrRecognitionController {
}

setOverlayBounds( entireScreenMode: 'fullscreen' | 'maximized' = 'fullscreen' ) {
console.time("setOverlayBounds");
// console.time("setOverlayBounds");

if ( this.captureSourceDisplay ) {

Expand Down Expand Up @@ -279,7 +279,7 @@ export class OcrRecognitionController {
// this.overlayWindow.setBounds( dipRect );
}

console.timeEnd("setOverlayBounds");
// console.timeEnd("setOverlayBounds");
}


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ export class OcrRecognitionService {
image?: Buffer,
window?: ExternalWindow
}> {
console.time('takeScreenshot');
// console.time('takeScreenshot');

const { display, window } = input;

Expand Down Expand Up @@ -110,7 +110,7 @@ export class OcrRecognitionService {
// id, display_id, name
// }));

console.timeEnd('takeScreenshot');
// console.timeEnd('takeScreenshot');

if ( !source )
return {};
Expand Down

0 comments on commit ec395c2

Please sign in to comment.