Version 0.7.x

For discussion directly related to ConwayLife.com, such as requesting changes to how the forums or home page function.
Post Reply
User avatar
Nathaniel
Site Admin
Posts: 862
Joined: December 10th, 2008, 3:48 pm
Location: New Brunswick, Canada
Contact:

Version 0.7.x

Post by Nathaniel » March 5th, 2009, 12:34 pm

Version beta 0.7.0 was uploaded today. The following changes since beta 0.6.0 have been made:

• Cleaned up some Java code so that the initial load time of the applet will hopefully be marginally shorter
• Fixed a bug involving the reading of Life 1.05 files (and possibly some other files as well)
• Fixed the rulestring bug (re: Flakes not working properly)
• Compressed some HTML by putting all of the popups together onto one popup whose content changes accordingly. This may or may not make the site run slightly faster
• Cleaned up some javascript that may have been causing occassional double submits when saving patterns (online or offline). It wouldn't have been very noticeable because the file wouldn't actually try to download twice, but it would've caused lag. At any rate, these actions should now be smoother.
• Added a "Save Image" option that automatically creates a BMP, GIF, or PNG of the current pattern (using the display settings you currently have selected). The maximum image size is 800x800. I hope to implement a feature that generates animated GIFs in the near future, but I haven't been able to figure that out yet.
• The "Save Image" option can also be accessed directly via URL. A simple example is as follows:
http://www.conwaylife.com/image.aspx?rle=bob$2bo$3o

Replace the RLE string (bob$2bo$3o) by any pattern's RLE encoding (the pattern does not have to be in the LifeWiki database for this to work). The given example produces an image (in PNG format) of a glider. There are several other options that can be added to the end of the querystring to customize the image:
- bc: The background color in HTML hexadecimal format. Defaults to #FFFFFF (white).
- cc: The cell color in HTML hexadecimal format. Defaults to #000000 (black).
- format: The image file format to be produced. Acceptable values are bmp, gif and png. Defaults to png.
- gc: The grid color in HTML hexadecimal format. Defaults to #C0C0C0 (light gray).
- grid: The width of the grid lines. Defaults to Floor((ppc + 12) / 16).
- h: The height (in cells) that the image should be. Defaults to the pattern's height.
- name: The default name that will appear when you try to save the image. Defaults to some gibberish.
- pad: The number of rows and columns of dead cells that should pad the outer edge of the pattern. Defaults to 1.
- ppc: The number of pixels per cell. Defults to 8.
- rle: An RLE encoding of a pattern. Defaults to "b" (an empty pattern).
- shape: The shape that the cells should be. Acceptable values are s (for square) and c (for circle). Defaults to s.
- w: The width (in cells) that the image should be. Defaults to the pattern's width.

As an example that makes use of some more of these parameters, consider:
http://www.conwaylife.com/image.aspx?rl ... 8FF&grid=0

• I added some querystring parameters to the website itself. These haven't been tested much yet, so they almost surely exhibit plenty of weird behavior (let me know if/when they do so). They are as follows:
- e: Whether or not the pattern loaded in can be edited manually by drawing (should be used in conjunction with the p parameter). Use e=0 to disable editing.
- g: Default number of generations per second.
- r: The default rules (can be in either the S/B format or the name of a rule like "amoeba") to be used.
- z: The default zoom level (0 = farthest away, 4 = closest).

Post Reply