Login
Username:

Password:

Remember me



Lost Password?

Register now!
Main Menu
Who is Online
5 user(s) are online (4 user(s) are browsing Forum)

Members: 0
Guests: 5

more...


Browsing this Thread:   1 Anonymous Users






Re: Strange filled-ellipse 24-bit colour bug
#6
Home away from home
Home away from home


See User information
The AreaEllipse() and WritePixel() 24-bit colour bugs should be fixed when the 2013-07-15 build appears (Sunday is a day of rest for the build server ). You'll need to take SYS:boot/aros-base.pkg.gz from it.

Posted on: 2013/7/14 7:58
 Top  Twitter  Facebook  Google Plus  Linkedin  Del.icio.us  Digg  Reddit  Mr. Wong 


Re: Strange filled-ellipse 24-bit colour bug
#5
Home away from home
Home away from home


See User information
@ncafferkey
Here is modified version which shows the truecolour bug when drawing ellipses:

Attach file:


Link only for registered users

Posted on: 2013/7/13 12:08
ChrisH
--
Author of the PortablE programming language.
 Top  Twitter  Facebook  Google Plus  Linkedin  Del.icio.us  Digg  Reddit  Mr. Wong 


Re: Strange filled-ellipse 24-bit colour bug
#4
Home away from home
Home away from home


See User information
Quote:
BTW, can you confirm that WritePixel() draws 24-bit colours on MorphOS and OS4? I know how to fix this on AROS, but I want to stay compatible.

Yes, it does draw 24-bit colours on AmigaOS4 & MorphOS. That is how I draw dots, but for AROS I currently have to draw 1x1 rectangles...

Posted on: 2013/7/13 11:44
ChrisH
--
Author of the PortablE programming language.
 Top  Twitter  Facebook  Google Plus  Linkedin  Del.icio.us  Digg  Reddit  Mr. Wong 


Re: Strange filled-ellipse 24-bit colour bug
#3
Home away from home
Home away from home


See User information
@ncafferkey
Strangely that works for me too. So I must be doing something slightly differently to your code, but at the moment I can't see what... (Whether that difference is a bug in my code or triggers a bug in AROS is another matter.)

EDIT: I realised why it's working - you are setting the colour EVERY time you draw an ellipse. But the colour only gets lost AFTER drawing the ellipse! I will make another post with a test program...

Posted on: 2013/7/13 11:40

Edited by PortablE on 2013/7/13 12:02:08
ChrisH
--
Author of the PortablE programming language.
 Top  Twitter  Facebook  Google Plus  Linkedin  Del.icio.us  Digg  Reddit  Mr. Wong 


Re: Strange filled-ellipse 24-bit colour bug
#2
Home away from home
Home away from home


See User information
I've attached an updated version of the truecolorpens test program (source and binary). It now draws filled ellipses (when you press space six times), and appears to work with 24-bit colours. I do see that it doesn't completely fill them however.

BTW, can you confirm that WritePixel() draws 24-bit colours on MorphOS and OS4? I know how to fix this on AROS, but I want to stay compatible.

Attach file:


Link only for registered users

Posted on: 2013/7/13 6:16
 Top  Twitter  Facebook  Google Plus  Linkedin  Del.icio.us  Digg  Reddit  Mr. Wong 


Strange filled-ellipse 24-bit colour bug
#1
Home away from home
Home away from home


See User information
When drawing a *filled* ellipse with a 24-bit colour (RPTAG_FgColor), the colour is lost after the first ellipse is drawn (I assume it reverts to the last palette-based pen).

This sounds similar to previous 24-bit colour drawing bugs, except that rather than the 24-bit colour not being used for drawing, instead the tidying-up of the filled ellipse seems to reset the colour & it is this resetting that is ignoring the 24-bit colour.

I'm afraid I don't have time to create a self-contained test case, but here is the relevant code:
Quote:
<pre>//init stuff needed for Area fill //this should really be done once, when the window is opened
areaSize = 2;
areaBuf= (signed char*) malloc(areaSize*5 * sizeof(signed char));
area = new struct AreaInfo;
InitArea(area, areaBuf, (short) areaSize);
rastport->AreaInfo = area;

tmpRasPlane = AllocRaster(width, height);
tmpRas = new struct TmpRas;
InitTmpRas(tmpRas, (void*) tmpRasPlane, (height * (((3 >= 0) ? width+15 >> 3 : width+15 << labs(3)) & 0xFFFE)));
rastport->TmpRas = tmpRas;

//draw an Area filled ellipse
AreaEllipse(rastport, x, y, radius, radius);
AreaEnd(rastport);

//clean-up
rastport->TmpRas = (struct TmpRas*) NULL;
delete tmpRas; tmpRas=NULL;
FreeRaster(tmpRasPlane, width, height);

rastport->AreaInfo = (struct AreaInfo*) NULL;
delete area;
free(areaBuf);</pre>


This code works on AmigaOS4, so it is *probably* correct, even if a bit strange/inefficient!

BTW, I notice that the filled ellipse is not actually 100% filled. So that's another bug!

Posted on: 2013/7/11 19:06
ChrisH
--
Author of the PortablE programming language.
 Top  Twitter  Facebook  Google Plus  Linkedin  Del.icio.us  Digg  Reddit  Mr. Wong 







You can view topic.
You cannot start a new topic.
You cannot reply to posts.
You cannot edit your posts.
You cannot delete your posts.
You cannot add new polls.
You cannot vote in polls.
You cannot attach files to posts.
You cannot post without approval.
You cannot use topic type.
You cannot use HTML syntax.
You cannot use signature.
You cannot create PDF files.
You cannot get print page.

[Advanced Search]


Search
Top Posters
1 paolone
paolone
4462
2 nikolaos
nikolaos
4206
3 magorium
magorium
4095
4 phoenixkonsole
phoenixkonsole
3942
5 deadwood
deadwood
2917
6 ncafferkey
ncafferkey
2810
7 mazze
mazze
2222
8 Kalamatee
Kalamatee
2212
9 clusteruk
clusteruk
2114
Powered by XOOPS © 2001-2025 The XOOPS Project