Jump to content

  • Log In with Google      Sign In   
  • Create Account

We need 7 developers from Canada and 18 more from Australia. to help us complete a research survey. We need your help! Support our site by taking a quick sponsored survey and win a chance at a $50 Amazon gift card. Click here to get started!


leagal4ever

Member Since 04 Jun 2012
Offline Last Active Aug 18 2015 01:33 PM

Posts I've Made

In Topic: sdl distorted SDL_FillRect and images

26 November 2012 - 02:38 PM

No, Init(); is in constructor it run only once, Render(); , Update(); and Fps(); run every frame

In Topic: sdl distorted SDL_FillRect and images

26 November 2012 - 02:00 PM

Yeah its tearning.

// init
SDL_Init(SDL_INIT_EVERYTHING);
screen = SDL_SetVideoMode(800, 600, 32, SDL_SWSURFACE | SDL_DOUBLEBUF);

// render
SDL_FillRect(screen, NULL, 0);
for(int i=0; i<box_vec.size(); i++)
{
SDL_FillRect(screen, &box_vec[i]->rect, box_vec[i]->color); // problem rect
}
SDL_Flip(screen);

// update
box_vec[i]->rect.x += box_vec[i]->xvel;
box_vec[i]->rect.y += box_vec[i]->yvel;

In Topic: c++, sdl - how to make installer? .exe

05 October 2012 - 05:15 PM

Oh souch silly error as told:

Just create the proper directory structure, add all relevant .dll and data files and pack it into zip archive.


I had no idea proper foler is Release folder there were no images i just copy SDL files.

SDL_Surface* tmp;
tmp = IMG_Load©;
SDL_DisplayFormatAlpha(tmp);// problem

Problem is there was no image loaded.

if (tmp != NULL)
SDL_DisplayFormatAlpha(tmp);
Now i avoid problem just in case something is not loaded


Thans for all help :)

In Topic: c++, sdl - how to make installer? .exe

05 October 2012 - 03:10 PM

Posted Image
I dont have any warnings have also minimize notices, when click on any Call Stack line only Dissembly lines are changed i dont see my code.

Posted Image
When run from Release folder i get window as normal with error message =(

I have made copy of project folder take most out and i have build it in Release so must be problem in my code.

In Topic: c++, sdl - how to make installer? .exe

04 October 2012 - 04:53 PM

Continue is just throwing same window with same message, break give me disassembly tab.
Posted Image

So somewhere in my code is mistake to somehow use NULL pointer, why there is no problem with debug mode?

PARTNERS