Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » Draw, Display, Images, Bitmaps, Icons » Draw stuff [SOLVED]
Re: Draw stuff [message #14069 is a reply to message #13903] Fri, 08 February 2008 16:02 Go to previous messageGo to previous message
Indio is currently offline  Indio
Messages: 8
Registered: January 2008
Location: Hungary
Promising Member
If I try like this, I only get the final image of the iteration. The images created from the results of the midsteps aren't shown.
It's only a test example.
int it;
Splitter splitter;
ImageCtrl outImgctrl;

Constructor(  )
{
  it = 1;
  splitter.Add(outImgctrl);
}

void Start(  )
{
	int itMaxNumber = 40;
	
	while( it < itMaxNumber )
	{
		MyDraw(  );
		it++;
	}
}

void MyDraw(  )
{
	ImageBuffer imgb(128, 128);
	
	for( int i = 0; i < 128; i++ )
	{
		RGBA *l = imgb[i];
		for( int j = 0; j < 128; j++ )
		{
                        // draws a line moving downwards
			if ( it == i )
			{
				l[j] = Black(  );
			}
			else
				l[j] = White(  );
		}
	}
	
	outImgctrl.SetImage( imgb );
	Refresh(  ); // needed? what's for?
}


What's wrong with this?

[Updated on: Fri, 08 February 2008 16:03]

Report message to a moderator

 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Optimized storage of 1BPP images
Next Topic: Drawing and scrolling
Goto Forum:
  


Current Time: Thu Aug 21 08:02:08 CEST 2025

Total time taken to generate the page: 0.05652 seconds