Chapter 16
Project Dibble
case 24: * (RGBTRIPLE *) pPixel = * (RGBTRIPLE *) &dwPixel ;
error #3114: [asm] Invalid combination of opcode and operand
Solution: cannot de-reference (RGBTRIPLE *) without typecasting to uintptr_t.
case 24: * (RGBTRIPLE *) pPixel = * (RGBTRIPLE *) (uintptr_t) (void *) &dwPixel ;
PellesC 9 issue.
A short example for that:
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
PellesC 9 issue.
A short example for that:
void __cdecl WinMainCRTStartup(void)
{
DWORD dwPix, dwPixel = 0x123456;
void *pPixel;
//pPixel = &dwPix; // test
* (RGBTRIPLE *) pPixel = * (RGBTRIPLE *) &dwPixel ;
* (RGBTRIPLE *) pPixel = * (RGBTRIPLE *) (void*) &dwPixel ;
ExitProcess(0);
}