KGS Leben: browser-powered, open-source KGS client

Comments, questions, rants, etc, that are specifically about KGS go here.
User avatar
Charlie
Lives in gote
Posts: 310
Joined: Mon Feb 06, 2012 2:19 am
Rank: EGF 4 kyu
GD Posts: 0
Location: Deutschland
Has thanked: 272 times
Been thanked: 126 times

Re: KGS Leben: browser-powered, open-source KGS client

Post by Charlie »

I'm travelling, tomorrow evening and over the weekend, and have five solid hours of German lessons in the morning so this is probably where my progress for the week grinds to a halt. In lieu of actually doing something useful - here's a link to some words about the game-area and some pictures showing off the SVG-powered byo-yomi clocks that I wrote, today: https://probabilism.wordpress.com/2016/ ... rs-clocks/

Es sieht sehr gut aus, oder?
User avatar
Bonobo
Oza
Posts: 2224
Joined: Fri Dec 23, 2011 6:39 pm
Rank: OGS 13k
GD Posts: 0
OGS: trohde
Universal go server handle: trohde
Location: Lüneburg Heath, North Germany
Has thanked: 8262 times
Been thanked: 924 times
Contact:

Re: KGS Leben: browser-powered, open-source KGS client

Post by Bonobo »

Charlie wrote:[..]

Es sieht sehr gut aus, oder?
Allerdings! :D
“The only difference between me and a madman is that I’m not mad.” — Salvador Dali
Morgoth Bauglir
Dies in gote
Posts: 25
Joined: Thu Mar 28, 2013 4:29 am
GD Posts: 0
Been thanked: 1 time

Re: KGS Leben: browser-powered, open-source KGS client

Post by Morgoth Bauglir »

Cool! Personally, I am struggling to make the KGS json client work for me as it seems to require the http POST and GET requests to be in sequence and there's no guarantee they will be once they go over a network. The only way to make it work is to do the http requests on the same host as the KGS json client and sending the results over a websocket connection.

Is there any particular reason why the KGS json client doesn't just implement javax.websocket.Endpoint and offer a websocket connection ? This would seems to me to make more sense when converting to from a tcp/ip connection and doesn't require buffering packets received from the tcp/ip connection for http GET requests to poll. Alternatively, the downstream packets could be numbered to prevent loss or out of sequence results.
Jhyn
Lives with ko
Posts: 202
Joined: Thu Sep 26, 2013 3:03 am
Rank: EGF 1d
GD Posts: 0
Universal go server handle: Jhyn
Location: Santiago, Chile
Has thanked: 39 times
Been thanked: 44 times

Re: KGS Leben: browser-powered, open-source KGS client

Post by Jhyn »

Charlie wrote:I'm travelling, tomorrow evening and over the weekend, and have five solid hours of German lessons in the morning so this is probably where my progress for the week grinds to a halt. In lieu of actually doing something useful - here's a link to some words about the game-area and some pictures showing off the SVG-powered byo-yomi clocks that I wrote, today: https://probabilism.wordpress.com/2016/ ... rs-clocks/

Es sieht sehr gut aus, oder?
Thank you for your selfless work, regardless of the outcome (althought I hope the outcome will be worth your investment!)

I have to say that I don't find the clock readable at all. I would do away with the black bars or at least make them much less visible. Having two "strong" colors that contrast with the background fighting for attention makes the value of the clock quite hard to read for me.
La victoire est un hasard, la défaite une nécessité.
YeGO
Dies with sente
Posts: 82
Joined: Mon Feb 23, 2015 8:41 pm
GD Posts: 0
Has thanked: 19 times
Been thanked: 46 times

Re: KGS Leben: browser-powered, open-source KGS client

Post by YeGO »

Exciting to hear about this project! Thanks!

Do you have any plans to open-source your work? I think there are a lot of developers that would be interested in contributing toward making this happen.
User avatar
Charlie
Lives in gote
Posts: 310
Joined: Mon Feb 06, 2012 2:19 am
Rank: EGF 4 kyu
GD Posts: 0
Location: Deutschland
Has thanked: 272 times
Been thanked: 126 times

Re: KGS Leben: browser-powered, open-source KGS client

Post by Charlie »

The player panels are more or less done: https://probabilism.wordpress.com/2016/ ... er-panels/

They're linked up to the game-state, too, and appear to be fully operational when testing on the live server. The clocks seem stable and don't jump about wildly due to network lag. They transition between time periods correctly and watching the little LCD segments that count Canadian overtime stones is a pleasure.

I now depart from the player panels and begin work on the end-of-game experience: handling resignation, results caused by timeout and scored culminations.

@Jhyn: I tweaked the seven-segment LCD styling a bit and faded the 'off' segments into the background. How's that for you?

@YeGO: Yes, I plan to open-source my work at some point.
User avatar
EdLee
Honinbo
Posts: 8859
Joined: Sat Apr 24, 2010 6:49 pm
GD Posts: 312
Location: Santa Barbara, CA
Has thanked: 349 times
Been thanked: 2070 times

Post by EdLee »

Charlie wrote:I tweaked the seven-segment LCD styling a bit and faded the 'off' segments into the background. How's that for you?
Hi Charlie,

Thank you very much for all your work.

Wish list/suggestions:
  • Wood grain board -- very nice. Please keep this option.
  • Slate stones -- nice. Please keep this option.
  • Please offer an option for "textbook" plain "flat", 2-D :black: & :white: stones.
  • Please offer an option for "real", photo-realistic Snow Grade shell stones.
    ( Definitely a 'luxury' option; that's why the above option for 'flat' 2-D B & W circles, as a backup. )
  • Please offer an option for non-LED clocks (plain, 'normal font' digits).
Thanks, again. :)
User avatar
ez4u
Oza
Posts: 2414
Joined: Wed Feb 23, 2011 10:15 pm
Rank: Jp 6 dan
GD Posts: 0
KGS: ez4u
Location: Tokyo, Japan
Has thanked: 2351 times
Been thanked: 1332 times

Re: KGS Leben: browser-powered, open-source KGS client

Post by ez4u »

Great stuff!!!

A couple of questions about your last post. On your website it says:
"When spectating, the away panel (pictured above) belongs to the stronger of the two players, or the white player in the case that the players are of equal rank."
Does this mean that if a 2d takes white against a 3d, the away panel will show Black while the home panel will show White? If so, I think this will be a little confusing as most observers are used to White being in the away panel regardless of strength. Isn't this the way the KGS client works now?

In your landscape mode screenshot is that a list of observers on the right side? They seem to be unordered (except for the players first). Is this the way that the server delivers the info? Hopefully you will include sorting the list and persistence in the preferred sorting. Personally I think wms made a huge mistake in not fixing the persistence of sorting preference that was broken when he fixed the sound issue. It made KGS much less user friendly for the high dans, which may or may not have a contributing factor to the decline in their presence.

One of my favorite players to observe is twoeye. His normal playing conditions are 80 periods of 10 seconds each. His games might be good ones to use to test your display since in your current layout it will require three rows of dots to show the beginning status with all 80 periods available. How much space will this take up in portrait mode?

Finally, is there any chance that you could release a test version that only allows the user to observe games (does not support playing) before you get all the heavy lifting done? My fingers are itching to see what KGS is like on my iPad. :)
Dave Sigaty
"Short-lived are both the praiser and the praised, and rememberer and the remembered..."
- Marcus Aurelius; Meditations, VIII 21
YeGO
Dies with sente
Posts: 82
Joined: Mon Feb 23, 2015 8:41 pm
GD Posts: 0
Has thanked: 19 times
Been thanked: 46 times

Re:

Post by YeGO »

Regarding the possibility of a photo-realistic stones and board mentioned by @EdLee, here are some free resources for implementing that:

It looks like the board of KGS Leben is generated using WGo.js, which recently added a photo-realistic option. See https://github.com/waltheri/wgo.js/pull/71. The stone and board images were contributed by https://github.com/atarnowsky/go-assets.

There is also a nice shinkaya wood grain photo provided by the jgoboard package. However, I think the color balance makes that image a little overly yellow. Hence, I modified the color levels of that image for my own project, see the shinkaya[2-4].jpg images in this folder.

I put these photo-realistic ingredients together in my own SGF editor.

Here's what it looks like:
IgoHatsuyoron.jpg
IgoHatsuyoron.jpg (291.02 KiB) Viewed 13615 times
User avatar
EdLee
Honinbo
Posts: 8859
Joined: Sat Apr 24, 2010 6:49 pm
GD Posts: 312
Location: Santa Barbara, CA
Has thanked: 349 times
Been thanked: 2070 times

Post by EdLee »

Hi YeGO,

Thanks for all the info.
'Photo-realistic' shell stones are very tricky:
for example, in your last screenshot,
the W stones look less like shell stones but
more like glass marbles with some 'wavy' internal streaks.
For good rendering of shell stones,
please see the current Panda clients,
and the (much older) gIgo, gGo clients.
YeGO
Dies with sente
Posts: 82
Joined: Mon Feb 23, 2015 8:41 pm
GD Posts: 0
Has thanked: 19 times
Been thanked: 46 times

Re: KGS Leben: browser-powered, open-source KGS client

Post by YeGO »

@EdLee:

The screenshot that I showed is rendered using actual photos of real stones, which are from this repository. Maybe they aren't the best pictures, but at least they are a nice, free asset that may be useful. As I was mentioning, it may be pretty straightforward to use them in this project, since rendering with these stone images is already a feature of the latest WGo.js, which appears to be a library used by KGS Leben (based on the appearance of the current board rendering).

Perhaps, this close-up screenshot may show the details of the stones a bit better:
detail.jpg
detail.jpg (90.26 KiB) Viewed 13598 times
It is indeed a bit tricky to render realistic stones. With these photos, the stones were actually lit from two opposite directions, necessitating double shadows, which may need further tweaking.

By the way, it does not appear that any of the programs that you mentioned (GoPanda clients, old and new) are actually even rendering photo-realistic shell stones. Perhaps, I'm mistaken and didn't look at the appropriate ones? Could you share a screenshot to help clarify? I would be very interested to learn about more software with good stone rendering.
User avatar
EdLee
Honinbo
Posts: 8859
Joined: Sat Apr 24, 2010 6:49 pm
GD Posts: 312
Location: Santa Barbara, CA
Has thanked: 349 times
Been thanked: 2070 times

Post by EdLee »

YeGO wrote:necessitating double shadows, which may need further tweaking.
Hi YeGO, yes, the shadows are part of the problem, and they definitely need more work.
The inconsistent, double light sources -- sometimes rotated -- is another problem.

I put 'photo realistic' in quotes; let me rephrase:
By 'good rendering', I mean aesthetically pleasing, or pretty, or beautiful.
Please see this thread, post 23.

As you noted correctly, to make the stones beautiful is more than 'simply' taking photos of real stones, and cropping them --
more 'post-editing' is necessary.

( Another aesthetic matter: in the screenshot in post 24,
the grid lines are too thick -- heavy & distracting.
One will never see thick lines like that on a good board.
At least the line width could be an adjustable option;
let each user pick their favorite thickness.
The aesthetic aspect of a good client is non-trivial: it runs in parallel to
good engineering. In general, I find the IGS clients -- gGo, gIGo, Panda, etc. -- very beautiful. )

Thanks.

From gIGo, a 2003 client -- note the consistent, single light source (top left direction):
gIGo.jpg
gIGo.jpg (581.91 KiB) Viewed 13564 times
Another 2007 editor, with real stone photos (non-randomized) -- note the elegant, single light source (top left direction):
mg.jpg
mg.jpg (813.04 KiB) Viewed 13563 times
From gGo, a 2002 client -- same, elegant stones & lines:
gGo.jpg
gGo.jpg (618.53 KiB) Viewed 13558 times
User avatar
yishn
Dies in gote
Posts: 57
Joined: Tue Jun 30, 2015 2:37 am
Rank: 4 kyu
GD Posts: 0
Location: Germany
Been thanked: 15 times
Contact:

Re: KGS Leben: browser-powered, open-source KGS client

Post by yishn »

People, we really should let Charlie finish the basic functionalities before overloading him with our own design preferences... ;-) Btw I find the stones in WGo.js player already very realistic and even better than glGo's.
User avatar
EdLee
Honinbo
Posts: 8859
Joined: Sat Apr 24, 2010 6:49 pm
GD Posts: 312
Location: Santa Barbara, CA
Has thanked: 349 times
Been thanked: 2070 times

Post by EdLee »

yishn, nobody is overloading anyone, with anything.
Of course, the basic functions are important.

It's fantastic that Charlie is even doing ALL this work.
We're very grateful. :bow:

These are suggestions; based on past experience (10+ years of Go clients usage).
From passionate people. Posted here for future reference. :)
If any is implemented, great; if not, it's not the end of the world.
I find the stones in WGo.js player already very realistic and even better than glGo's.
Different people will have various preferences (different from yours, different from mine);
thus the suggestion to at least add the most basic, no-frills 2D flat B & W circles -- as a fall-back, basic option.
Because some people like iOS, others Windows, still others Android, etc.
All very different eyes and tastes.
Jhyn
Lives with ko
Posts: 202
Joined: Thu Sep 26, 2013 3:03 am
Rank: EGF 1d
GD Posts: 0
Universal go server handle: Jhyn
Location: Santiago, Chile
Has thanked: 39 times
Been thanked: 44 times

Re: KGS Leben: browser-powered, open-source KGS client

Post by Jhyn »

Charlie wrote:@Jhyn: I tweaked the seven-segment LCD styling a bit and faded the 'off' segments into the background. How's that for you?
It is much better; the readability is greatly improved. I might have some additional suggestions but nothing of that importance, as yishn says, this is a bit early for that and it might be better to wait for a final overall design before tweaking the details. Again this is great work.
La victoire est un hasard, la défaite une nécessité.
Post Reply