Angband.oook.cz
Angband.oook.cz
AboutVariantsLadderForumCompetitionComicScreenshotsFunniesLinks

Go Back   Angband Forums > Angband > Development

Reply
 
Thread Tools Display Modes
Old May 11, 2012, 10:02   #1
PowerWyrm
Prophet
 
PowerWyrm's Avatar
 
Join Date: Apr 2008
Posts: 2,966
PowerWyrm is on a distinguished road
Display glitch with GCU client?

In order to play with Necklace of the Eye with my variant, I've compiled a GCU client using PDCURSES 3.4 (I'm on Win7)... but I face some weird display glitches.

Below is an example of what's happening. When the character moves from the left side of the room to the right side, the walls are incorrectly redrawn until I press ctrl-R to redraw the screen. It seems that every single character that is drawn is one pixel too large.

I'm wondering... Since the client only displays ASCII symbols using Term_text_gcu(), this problem shouldn't happen unless there's some obscure bug in the curses library. Can anyone tell me if there's the same problem with V?
Attached Images
 
__________________
PWMAngband variant maintainer - check https://github.com/draconisPW/PWMAngband (or http://www.mangband.org/forum/viewforum.php?f=9) to learn more about this new variant!

Last edited by PowerWyrm; May 11, 2012 at 10:16.
PowerWyrm is offline   Reply With Quote
Old May 13, 2012, 03:28   #2
d_m
Angband Devteam member
 
d_m's Avatar
 
Join Date: Aug 2008
Location: Philadelphia, PA, USA
Age: 43
Posts: 1,516
d_m is on a distinguished road
Quote:
Originally Posted by PowerWyrm View Post
I'm wondering... Since the client only displays ASCII symbols using Term_text_gcu(), this problem shouldn't happen unless there's some obscure bug in the curses library. Can anyone tell me if there's the same problem with V?
It may be a problem with wide text (unicode) on Windows, which is UCS-2/UTF-16. That would be a bit ugly to diagnose.

It may also be a problem with using reverse video'd spaces for walls (e.g. using A_REVERSE). You could test this by changing granite walls from:

Code:
F:56:all:0x81:0x20
into:

Code:
F:56:all:0x01:0x23
Other than those two things, I'm not sure what it could be besides a bug in the curses library.
__________________
linux->xterm->screen->pmacs
d_m is offline   Reply With Quote
Old May 22, 2012, 13:16   #3
PowerWyrm
Prophet
 
PowerWyrm's Avatar
 
Join Date: Apr 2008
Posts: 2,966
PowerWyrm is on a distinguished road
Not a problem with Unicode, I've tried using the non-Unicode functions to display the characters and I still have the problem.

Not a problem with walls, it's still happening when using the basic # character to display walls.

Then it's a bug in the curses library... dammit.
__________________
PWMAngband variant maintainer - check https://github.com/draconisPW/PWMAngband (or http://www.mangband.org/forum/viewforum.php?f=9) to learn more about this new variant!
PowerWyrm is offline   Reply With Quote
Old May 22, 2012, 17:03   #4
d_m
Angband Devteam member
 
d_m's Avatar
 
Join Date: Aug 2008
Location: Philadelphia, PA, USA
Age: 43
Posts: 1,516
d_m is on a distinguished road
Quote:
Originally Posted by PowerWyrm View Post
Then it's a bug in the curses library... dammit.
Ouch

Well, I know that a windows console mode used to work, so I think there must be some library out there that can do it. May require some serious #ifdef stuff though...

Anyway, good luck!
__________________
linux->xterm->screen->pmacs
d_m is offline   Reply With Quote
Old May 25, 2012, 15:26   #5
PowerWyrm
Prophet
 
PowerWyrm's Avatar
 
Join Date: Apr 2008
Posts: 2,966
PowerWyrm is on a distinguished road
The problem arises when using colors. Printing everything in white using wattrset(window, 0) doesn't produce the glitch. But as soon as you use wattrset(window, somecolor), the glitch happens.

I'll try to figure out if something in the current main-gcu code produces the problem, or if it comes from pdcurses. If it's a bug with pdcurses, the only other option is to download ncurses 5.9 and try the new Windows Console port that can be compiled with MinGW.
__________________
PWMAngband variant maintainer - check https://github.com/draconisPW/PWMAngband (or http://www.mangband.org/forum/viewforum.php?f=9) to learn more about this new variant!
PowerWyrm is offline   Reply With Quote
Old May 26, 2012, 00:19   #6
d_m
Angband Devteam member
 
d_m's Avatar
 
Join Date: Aug 2008
Location: Philadelphia, PA, USA
Age: 43
Posts: 1,516
d_m is on a distinguished road
Quote:
Originally Posted by PowerWyrm View Post
The problem arises when using colors. Printing everything in white using wattrset(window, 0) doesn't produce the glitch. But as soon as you use wattrset(window, somecolor), the glitch happens.

I'll try to figure out if something in the current main-gcu code produces the problem, or if it comes from pdcurses. If it's a bug with pdcurses, the only other option is to download ncurses 5.9 and try the new Windows Console port that can be compiled with MinGW.
The other thing I could imagine is that maybe pdcurses is trying to support 88 or 256 colors and failing? Or that it purports to be able to reset colors? In those cases, hard-disabling those features might also help.
__________________
linux->xterm->screen->pmacs
d_m is offline   Reply With Quote
Old June 8, 2012, 14:26   #7
PowerWyrm
Prophet
 
PowerWyrm's Avatar
 
Join Date: Apr 2008
Posts: 2,966
PowerWyrm is on a distinguished road
This is clearly a bug with PDCurses, as someone else reported the same problem on pdcurses's sourceforge bug tracker.

Today I've tried something really challenging... recompiling the GCU client using NCURSES... under Windows! With the latest 5.9 version, there is a Windows build that can be compiled using minGW. Unfortunately I don't have my source code configured for minGW, so I had to configure ncurses using minGW to get the headers and defines, plug the resulting ncurses source code into my BCC project, fix the few compile errors due to not having minGW headers (sys/time.h and such) and then adapt main-gcu. But it works!

The only problem here, as stated in the ncurses readme file, is that ncurses 5.9 has no widechar support when compiled under Windows. This means no fancy walls...
__________________
PWMAngband variant maintainer - check https://github.com/draconisPW/PWMAngband (or http://www.mangband.org/forum/viewforum.php?f=9) to learn more about this new variant!
PowerWyrm is offline   Reply With Quote
Old June 9, 2012, 00:14   #8
Nick
Vanilla maintainer
 
Nick's Avatar
 
Join Date: Apr 2007
Location: Canberra, Australia
Age: 58
Posts: 9,526
Donated: $60
Nick will become famous soon enoughNick will become famous soon enough
Cool. Now we can play in terminals on every platform and ditch all that funky platform specific code
__________________
One for the Dark Lord on his dark throne
In the Land of Mordor where the Shadows lie.
Nick is offline   Reply With Quote
Old June 9, 2012, 17:30   #9
d_m
Angband Devteam member
 
d_m's Avatar
 
Join Date: Aug 2008
Location: Philadelphia, PA, USA
Age: 43
Posts: 1,516
d_m is on a distinguished road
Quote:
Originally Posted by Nick View Post
Cool. Now we can play in terminals on every platform and ditch all that funky platform specific code
You said it!
__________________
linux->xterm->screen->pmacs
d_m is offline   Reply With Quote
Old June 11, 2012, 13:08   #10
PowerWyrm
Prophet
 
PowerWyrm's Avatar
 
Join Date: Apr 2008
Posts: 2,966
PowerWyrm is on a distinguished road
Quote:
Originally Posted by PowerWyrm View Post
The only problem here, as stated in the ncurses readme file, is that ncurses 5.9 has no widechar support when compiled under Windows. This means no fancy walls...
Alright... I've regenerated the minGW configuration using --enable-widec to add w_char support (mvwaddnwstr and co.). Now it's time to see if I can plug the fancy walls back...
__________________
PWMAngband variant maintainer - check https://github.com/draconisPW/PWMAngband (or http://www.mangband.org/forum/viewforum.php?f=9) to learn more about this new variant!
PowerWyrm is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
[3.4-dev] Minor bugs with Win client PowerWyrm Development 0 April 18, 2012 13:17
Minor glitch with item selection PowerWyrm Development 2 February 10, 2012 16:26
[3.3.x] SDL client: unable to perform some commands PowerWyrm Vanilla 2 November 1, 2011 15:58
Graphics glitch in OSX version willpax Vanilla 5 January 15, 2009 14:07
Minor display glitch in 3.0.9 Dragonboneman Vanilla 17 October 26, 2007 18:04


All times are GMT +1. The time now is 07:18.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2023, vBulletin Solutions Inc.