/Home

https://chessforeva.gitlab.io
......... ...........
.... ....

Chess software for fun

otrdiena, 2009. gada 9. jūnijs

Chessforeva diagram sample

 2D plane and simple

 The tool to draw diagram pictures for chess puzzles from a given FEN. Right-click on canvas to save the picture. Also usable as web-link for iframe presentation, samples:


https://chessforeva.gitlab.io/C0_dg2.htm?fen=6K1/p7/P2kPp1Q/1p1NR3/3N3P/2P2Pp1/3P4/8_w_&to=1&last=c7d6
https://chessforeva.gitlab.io/C0_dg2.htm?fen=8/2K2p2/B7/2k2P2/5N2/2B5/8/8_w_&lb=1&to=1&sz=38

https://chessforeva.gitlab.io/C0_dg2.htm?fen=rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR_w_QKqk_-_0_1&sz=100&lb=1&to=1

https://chessforeva.gitlab.io/C0_dg2.htm?fen=rnbqkbnr/ppppp2p/5p2/6p1/4P3/2N5/PPPP1PPP/R1BQKBNR_w_QKqk_g6_0_3&lb=1&to=1&last=g7g5

 url parameters:

  • fen=... FEN of chess posirion
  • to=1 , if should see which side to move
  • lb=1 , labels a-h,1-8
  • sz=38 , the 2nd smaller pics (exactly 38px)
  •  or sz=100 , the laser printer version no color (exactly 100px, HQ .svg pieces by User:Cburnett)
  • last=... , if the last move is interesting too
  • style=width:300 , any resizing is possible, otherwise 8 x 70px

Draw a  picture and save, that's all. Since jan.,2021.


3D experimental

This is a diagram sample based on programming scripts



Code:

<script src="https://chessforeva.gitlab.io/c0_chess.js" type="text/javascript"></script>

<script type="text/javascript">
c0_initall();
c0_at_top=80;c0_at_left=10;
c0_side=-1;
c0_relative_size_procents=50;
c0_zoom=false;
c0_draw_empty_board();
c0_set_start_position("e2e4c7c5g1f3b8c6d2d3");
</script>


If You wish to use it for serious publication purposes then better use each board in separate frame.
<iframe src="http://...." width="400" height="280" frameborder="0"></iframe>

Otherwise the board lives it's own and only life in the browser. Separate it and avoid problems.

See also the other blog post.

Nav komentāru:

Ierakstīt komentāru

SiteMap: Index of/ ..
Blogposts:
free counters