Category Archive: IT

Anything about IT

Aug 14

2015 AGE Gaming show

Actually, this is my 10th years to attend AGE gaming show. Noting is very exciting, but game, Britney spears, is very impressive. The game is specially designed for curve screen to suit physical curve, and the chair has stereo surrounding sound system, and event it can shake up when reel spinning stops.

Aug 02

Share Brother HL-2130 through Lenovo Iomega EZ Media & Backup Center USB port

Recently I bought a Lenovo® EZ Media and Backup Center to share video and photos within my home network. I also have a Brother HL-2130 Mono Laser long time back which is connected to my PC USB port. Every time, when I want to print something, I have to keep my PC on. I am …

Continue reading »

Jul 10

Convert DIB or BMP into JPEG in memory (diskless) using Windows GDIPlus

#include #include using namespace Gdiplus; GdiplusStartupInput gdiplusStartupInput; ULONG_PTR gdiplusToken; GdiplusStartup(&gdiplusToken, &gdiplusStartupInput, NULL); … IStream* pJpegStream = NULL; //declare a memory stream CreateStreamOnHGlobal(NULL, TRUE, (LPSTREAM*)&pJpegStream); GpBitmap* pBitmap = NULL; unsigned char* dib = GetDib(); //get DIB or BMP data buffer DllExports::GdipCreateBitmapFromGdiDib((LPBITMAPINFO)dib, dib + sizeof(BITMAPINFOHEADER), &pBitmap); CLSID imageCLSID; GetEncoderClsid(L”image/jpeg”, &imageCLSID); int jpegQuality = 100; EncoderParameters encoderParams; //setup …

Continue reading »

Jun 03

Programmably dislable Windows Firewall in C/C++

// firewall.cpp : Defines the entry point for the console application. // #include “stdafx.h” /********************************************************************++ Copyright (C) Microsoft. All Rights Reserved. Abstract: This C++ file includes sample code for disabling Windows Firewall per profile using the Microsoft Windows Firewall APIs. –********************************************************************/ #include #include #include #pragma comment( lib, “ole32.lib” ) // Forward declarations HRESULT WFCOMInitialize(INetFwPolicy2** ppNetFwPolicy2); …

Continue reading »

Apr 10

Maximize the output of your CPU (Keep your CPU in full power mode)

Recently I am working on UI decoding optimization. I found this program, Full Throttle Override, is very useful, and it can fully release the power of your CPU. To balance of power consumption and performance, almost all x86 CPUs support either Cool’n’Quiet or SpeedStep or PowerNow! technology, which can dynamically adjust the CPU frequency based on …

Continue reading »

Mar 26

Feel the power of parallel computing (OpenMP)

These two weeks, I am working on our product UI side to improve the performance of animation rendering. Previously, there is only one single thread to decode the animation line by line, and it takes around 50ms for the whole frame. Now, I change the way of rendering, and let all lines parallel decode to …

Continue reading »

Mar 05

Microsoft .NET Framework 4.x Redistributable Installer Link

Sometimes, it’s hard to find Microsoft .Net framework 4.x installer link. Here is my collections for the link:   .NET Framework version Redistributable installation 4.6 Preview Download page for 4.6 web installer Download page for 4.6 offline installer 4.5.2 Download page for 4.5.2 web installer Download page for 4.5.2 offline installer 4.5.1 Download page for …

Continue reading »

Mar 05

Download a hotfix without contacting Microsoft?

I am working on Windows 7 Embedded recently, and need some hotfix, which is not publicly released by Microsoft. I found this article very useful. How can you download a hotfix without contacting Microsoft? Here is the tricks: A customer can get the fix they want without calling in to Microsoft, assuming they know the …

Continue reading »

Feb 26

My first x64 assembly code cooked by hand

This is my first hand made x64 assembly code. extrn MessageBoxA:proc .DATA CONST SEGMENT msg DB “Hello World!”, 0 CONST ENDS .CODE main PROC sub rsp, 28h xor rcx, rcx lea rdx, msg lea r8, msg xor r9, r9 call MessageBoxA main ENDP END To compile this code, in command prompt run ml64 helloworld.asm /link …

Continue reading »

Dec 08

Resize photo in C#

Today, my friend asked me to recommend a free resize photo tool, and he got lots of photos. I really don’t know. Normally I use MS Paint and select Stretch and Skew. If here are many photos, it would take ages. I then wrote a small tool for him using C#. The code is fairly …

Continue reading »

Older posts «

» Newer posts