NO

Recent Posts

Pages: [1] 2 3 ... 10
1
Graphics programming / Re: Why GDIplus dont work?
« Last post by bitcoin on Today at 10:39:20 am »
Yes, it works. Thanks Timo!

But why? When I type 'Inch', it draw in another place?
2
User contributions / Re: Editor for convolutions filters
« Last post by Grincheux on Today at 09:57:42 am »
I do not publish any changes from now within two months.
I made a lot of changes and corrected a mountain of bugs:
Everyday I work with the program during many hours to find what is wrong.
For now it seems clean.

https://www.mediafire.com/file/w7bgnudn0pyrgpo/Cfe-Setup-Sources.exe/file is a link on the full source code.
and https://www.mediafire.com/file/9gd06wkttk35v7p/Cfe-Setup.exe/file is the link on the lat version.

Source code = Binaries

Play with it you will be very surprised if you think you where pretty... I test on me and did not recognized myself.

There is an other domain that I would like to include, it is the CNN seems not too complicated...

Telle me what is wrong or what could be improved, that would help me.
3
Graphics programming / Re: Why GDIplus dont work?
« Last post by TimoVJL on Today at 07:02:16 am »
Try UnitPixel instead
4
Graphics programming / Why GDIplus dont work?
« Last post by bitcoin on Today at 01:52:30 am »
Hello, I try to code gdi plus, and this no draw anything! And no errors..why?

Code: [Select]
#include <windows.h>
#include <fgdiplusflat.h>

#pragma comment (lib,"Gdiplus.lib")


VOID OnPaint(HDC hdc)
{
GpStatus g_ok;
Graphics graphics;
Pen pen;

TextOut(hdc, 0, 0, "Hello, Windows!", 15);

g_ok = GdipCreateFromHDC(hdc,&graphics);

if(g_ok != Ok)
{
WCHAR errCode[4];
wsprintfW(errCode,L"%d",g_ok);
MessageBoxW(0,errCode,L"GdipCreateFromHDC",MB_OK);
return;
}

g_ok = GdipCreatePen1(MakeARGB(255, 0, 0, 255),1.0,UnitInch,&pen);

if(g_ok != Ok)
{
WCHAR errCode[4];
wsprintfW(errCode,L"%d",g_ok);
MessageBoxW(0,errCode,L"GdipCreatePen1",MB_OK);
return;
}
g_ok = GdipDrawLine(graphics,pen, 20, 20, 200, 100);
if(g_ok != Ok)
{
WCHAR errCode[4];
wsprintfW(errCode,L"%d",g_ok);
MessageBoxW(0,errCode,L"GdipDrawLine",MB_OK);
return;
}
GdipDrawRectangle(graphics, pen, 20, 20, 120, 120);
GdipDeletePen(pen);
     GdipDeleteGraphics(graphics);


}

LRESULT CALLBACK WndProc(HWND, UINT, WPARAM, LPARAM);

INT WINAPI WinMain(HINSTANCE hInstance, HINSTANCE h, PSTR ss, INT iCmdShow)
{
HWND                hWnd;
MSG                 msg;
WNDCLASS            wndClass;
GdiplusStartupInput gdiplusStartupInput = { 1, NULL, 0, 0 };
ULONG_PTR           gdiplusToken;

// Initialize GDI+.
if(GdiplusStartup(&gdiplusToken, &gdiplusStartupInput, NULL))
MessageBoxW(0,L"Err GdiplusStartup",0,0);

wndClass.style = CS_HREDRAW | CS_VREDRAW;
wndClass.lpfnWndProc = WndProc;
wndClass.cbClsExtra = 0;
wndClass.cbWndExtra = 0;
wndClass.hInstance = hInstance;
wndClass.hIcon = LoadIcon(NULL, IDI_APPLICATION);
wndClass.hCursor = LoadCursor(NULL, IDC_ARROW);
wndClass.hbrBackground = (HBRUSH)GetStockObject(WHITE_BRUSH);
wndClass.lpszMenuName = NULL;
wndClass.lpszClassName = TEXT("GettingStarted");

RegisterClass(&wndClass);

hWnd = CreateWindow(
TEXT("GettingStarted"),   // window class name
TEXT("Getting Started"),  // window caption
WS_OVERLAPPEDWINDOW,      // window style
CW_USEDEFAULT,            // initial x position
CW_USEDEFAULT,            // initial y position
CW_USEDEFAULT,            // initial x size
CW_USEDEFAULT,            // initial y size
NULL,                     // parent window handle
NULL,                     // window menu handle
hInstance,                // program instance handle
NULL);                    // creation parameters

ShowWindow(hWnd, iCmdShow);
UpdateWindow(hWnd);

while (GetMessage(&msg, NULL, 0, 0))
{
TranslateMessage(&msg);
DispatchMessage(&msg);
}

GdiplusShutdown(gdiplusToken);
return msg.wParam;
}  // WinMain

LRESULT CALLBACK WndProc(HWND hWnd, UINT message,WPARAM wParam, LPARAM lParam)
{
HDC          hdc;
PAINTSTRUCT  ps;

switch (message)
{
case WM_PAINT:
hdc = BeginPaint(hWnd, &ps);
if(!hdc)
MessageBoxW(0,L"Err",NULL,0);
OnPaint(hdc);
EndPaint(hWnd, &ps);
return 0;
case WM_DESTROY:
PostQuitMessage(0);
return 0;
default:
return DefWindowProc(hWnd, message, wParam, lParam);
}
} // WndProc
5
Assembly discussions / Re: Initializing local variables
« Last post by Vortex on Yesterday at 10:05:34 pm »
Hi Grincheux,

Code: [Select]
PUBLIC   ClearMem
No need of this statement as procedures are visible to the external modules by default.

Code: [Select]
xchg   rdx,rcx
You could remove this line. Redefining the procedure :

Code: [Select]
ClearMem  PROC   __dwNumberOfBytes:DWORD,__lpPointer:QWORD PARMAREA=4*QWORD
6
User contributions / Re: Memory Leaks
« Last post by Grincheux on Yesterday at 12:34:53 pm »
Don't need it, remove the include.


This a file for computing a crc on 64 bits.
I join them if they can help you.
7
User contributions / Re: Memory Leaks
« Last post by bitcoin on Yesterday at 12:32:13 pm »
Thank you, good thing. Will be test it.
But where I can get #include "crc64speed.h" ?
8
User contributions / Memory Leaks
« Last post by Grincheux on Yesterday at 07:28:30 am »
Small functions to help to detect memory leaks.
It uses VirtualAlloc and creates a database where you can see the result of VirtualAlloc and VirtualFree

Example:
Code: [Select]
#ifdef __MEMORY_LEAKS__
   _lpImageInfos = (LPIMAGEINFOS) MemoryLeaks_Alloc(__LINE__,"LoadImageFromFile",sizeof(IMAGEINFOS) + 1024) ;
#else
   _lpImageInfos = (LPIMAGEINFOS) VirtualAlloc(NULL,sizeof(IMAGEINFOS) + 1024,MEM_COMMIT|MEM_RESERVE,PAGE_READWRITE) ;
#endif
   if(_lpImageInfos)

and the result:
Quote
RecNo   Action   LineNumber   Function   MemorySize   Address   Result
1   VirtualAlloc   3250   CreateFilter   3991   A6F30000   1
84   VirtualFree   4584   Main_OnDestroy   0   A6F30000   1
2   VirtualAlloc   1425   LoadImageFromFile   26088   A6F50000   1
83   VirtualFree   1540   ImageFree   0   A6F50000   1
73   VirtualAlloc   3350   SaveDatas   32768   A6F60000   1
74   VirtualFree   3425   SaveDatas   0   A6F60000   1

If that can help you...
9
Announcements / Re: Server problems due to an issue at the provider
« Last post by MrBcx on April 13, 2021, 04:52:34 pm »
I will try to fix this issue within the next week.
Best regards
Christian

“Do or do not, there is no try”  -- Yoda

I've discovered http://www.pellesc.com can be made to redirect to https://forum.pellesc.de, if entered manually.

That doesn't solve anything -- it's only an observation.

10
Announcements / Re: Server problems due to an issue at the provider
« Last post by Christian on April 13, 2021, 12:33:05 pm »
Hello,

I will try to fix this issue within the next week.

Best regards

Christian
Pages: [1] 2 3 ... 10