Page MenuHome
Paste P1100

notecracker.py
ActivePublic

Authored by Nathan Letwory (jesterking) on Sep 14 2019, 1:00 AM.
import re
import textwrap
MAX_WIDTH = 70
# image links
imgptrn = re.compile(r"!\[.*?\]\(.*?\)")
# regular links
lnkptrn = re.compile(r"(\s|[^!\w])(\[.*?\]\(.*?\))")
# constituents of links
lnkfrmt = re.compile(r"\[(.*?)\]\((.*?)\)")
# top header
topptrn = re.compile(r"^[#]{2} (.*?)$", re.M)
# sub header
subptrn = re.compile(r"^[#]{4} (.*?)$", re.M)
thetext = """
Notes for developer meeting 9 September 2019.
## Announcements
* Buildbot now supports building arbitrary branches. Developers can use this to test their branch builds and passes tests on all platforms, and to make the branch available to users for testing. ([docs](https://wiki.blender.org/wiki/Infrastructure/BuildBot#Branch_Builds)) (_Brecht Van Lommel_)
## New Features and Changes
#### Eevee
Soft shadows were redesigned and are now enabled with the "Use Soft Shadow" option in the render properties Shadow panel. This will progressively smooth shadows, in combination with a more conventional shadow filtering method (PCF). Exponential and Variance Shadow Mapping methods were removed. ([details](https://wiki.blender.org/wiki/Reference/Release_Notes/2.81/Eevee#Shadows_Redesign)) (_Clément Foucault_)
This improves shadow accuracy, makes light and shadow setup simpler, and improves performance for soft shadows.
Bump mapping was changed to give more accurate results closer to Cycles. In particular it makes bump mapping with procedural textures work much better than before, at the cost of some performance.
![81_eevee_shadows|690x388](upload://8tz5FnL3IedJkO1YajQJQQrq6xG.jpeg)
#### Cycles
Reduced shadow terminator artifacts for bump mapping with diffuse BSDFs. (_Lukas Stockner, Stefan Werner_)
![81_bump_before|690x388,340x](upload://wP7VT3jObbtJWELKcyBcC9mYCoN.jpeg) ![81_bump_after|690x388,340x](upload://qzU4TatmJJmjlUw7d6PwPABUGv8.jpeg)
#### Shaders
New shader nodes for Cycles & Eevee. (_Omar Ahmad_)
* Noise Texture node: support 1D, 2D, and 4D noise.
* Mapping node: location, rotation and scale are now node inputs that can be linked to other nodes.
#### Viewport
Viewport shading changes to support look development with Cycles. (_Jeroen Bakker_)
* Rendered mode now has option to use HDRI studio lights instead of scene lights and world, for both Cycles and Eevee. This mode can now be used for look development.
* LookDev mode was renamed to Material Preview. This mode will be aimed at interactive texturing and fast preview with Eevee.
* HDRI studio light strength can now be controlled in the shading popover.
#### File Browser
The file Browser was redesigned. ([details](https://developer.blender.org/rBee8f69c96cba62b083fb089432cddd0bce5d08e1)) (_Julian Eisel, Brian Meisenheimer, William Reynish, Harley Acheson, Andrzej Ambroz_)
* File Browser as floating window with more standard layout
* Popovers for view and filter options
* Importer/exporter options in panels in the sidebar
* Vertical list view with interactive column header
* New and updated icons
* More consistent and powerful mouse and keyboard shortcuts, including range select with shift click and extend select with ctrl click.
![81_file_browser_fbx|690x425](upload://jnNrifX8YDUJY52hYqk8j5kszxG.jpeg)
#### Rigging
* Armatures: bone inherit scale options ([details](https://developer.blender.org/rBfcf2a712eca278f198e8d61845f2078088af1f9a)) (_Alexander Gavrilov_)
* Full: inherit all effects of scale, like with enabled Inherit Scale.
* Fix Shear: removes shear from the final inherited transformation.
* Average: inherit uniform scale that represents the parent volume.
* None: completely remove scale and shear.
* None (Legacy): previous behavior for backwards compatibility.
* Constraints: better mixing modes for Copy Rotation and Copy Transform (_Alexander Gavrilov_)
* Replace: Replace the original transformation with copied
* Add: Add euler component values together
* Before Original: Apply copied transformation before original, as if the constraint target is a parent
* After Original: Apply copied transformation after original, as if the constraint target is a child
* Drivers: support decomposing rotation into swing followed by twist ([details](https://developer.blender.org/rBe91ea20ebee800600ec073f9738b448778372453)) (_Alexander Gavrilov_)
* Python API: constraints can now be reordered with `move()` on objects and bones. (_Alexander Gavrilov_)
#### Other
* Image objects option to only show in side views (_Campbell Barton_)
* Grease Pencil (_Antonio Vazquez, Charlie Jolly_)
* Convert to strokes support for poly curves
* Viewport option to fade unselected objects.
* Improved guides display, with new Isometric option
* User Interface
* Select tool was renamed to Tweak tool. (_William Reynish_)
* Paint mode shortcuts: D for draw brush, B for blur brush. (_William Reynish_)
* Viewport navigation buttons are now positioned vertically.
* Batch rename now supports regular expression groups. (_Jun Mizutani, Campbell Barton_)
## Projects Under Development
* (2.81) GPencil patches up for review still ([D5688](https://developer.blender.org/D5688), [D5707](https://developer.blender.org/D5707)) (_Antonioya, Brecht Van Lommel_)
* (2.81) Potential UV patches (_Sebastian Parborg, Phil Gosh, Brecht Van Lommel_)
* (2.81) Potential DNA defaults patch ([D4500](https://developer.blender.org/D4500)) (_Campbell Barton, Brecht Van Lommel_)
* Add-ons
* Clean-up of add-ons repository: ([T63750](https://developer.blender.org/T63750)) (_Brendon Murphy_)
* X3D IO moved to community support, no longer maintained by the core team.
* In short: no maintainer = no entry.
* Speak up if there is an issue for you with this, see previous bullet item.
* Crashes with Python frame change handlers are being worked on, which requires some internal redesign. ([T60094](https://developer.blender.org/T60094)) (_Sergey Sharybin, Brecht Van Lommel_)
## Next meeting
Next meeting Next online meeting is on Monday, 16 September 18:00 CEST / 16:00 UTC. It will be on [#blender-coders on blender.chat](https://blender.chat/channel/blender-coders). ([details](https://wiki.blender.org/wiki/Communication/Contact#Weekly_Developer_Meetings))
## Weekly Progress Reports
* [Bastien](https://wiki.blender.org/wiki/User:Mont29/Foundation/2019#Week_312_-_08.2F31_to_09.2F06)
* [Brecht](https://wiki.blender.org/wiki/User:Brecht/Reports/2019#September_2_-_6)
* [Campbell](https://download.blender.org/ftp/ideasman42/donelist/2019.html#week-342-september-2)
* [Clément](https://wiki.blender.org/wiki/User:Hypersomniac/Foundation/2019)
* [Dalai](https://wiki.blender.org/wiki/User:Dfelinto/Reports/2019#September_2_-_6)
* [Germano](https://wiki.blender.org/wiki/User:Manowii/Reports/2019#Week_10:_2nd_-_6th_September)
* [Jacques](https://wiki.blender.org/wiki/User:JacquesLucke/Reports/2019#Week_49:_September_02_-_06)
* [Jeroen](https://wiki.blender.org/wiki/User:Jbakker/reports/2019#Week_201936:_2019.2F09.2F02_-_2019.2F09.2F08)
* [Julian](https://wiki.blender.org/wiki/User:Severin/Reports/Institute_2019#September_1_-_September_8)
* [Nathan](https://wiki.blender.org/wiki/User:JesterKing/Reports/2019#September_2_-_September_6_.2F_.2310)
* [Philipp](https://wiki.blender.org/wiki/User:PhilippOeser/Foundation/2019#Calendar_Week_36_.28Sep_2nd_-_Sep_6th.29)
* [Sebastian](https://wiki.blender.org/wiki/User:Zeddb#Sep_02_-_Aug_06)
* [Sergey](https://wiki.blender.org/wiki/User:Sergey/Foundation/2019#Week_401:_2nd_-_8th_September)
* [Sybren](https://wiki.blender.org/wiki/User:Sybren/Reports/2019)
"""
imagesmatches = re.findall(imgptrn, thetext)
for im in imagesmatches:
thetext = thetext.replace(im, "")
lines = [line.rstrip() for line in thetext.splitlines()]
thetext = "\n".join(lines)
linksmatches = re.findall(lnkptrn, thetext)
links = [ln[1] for ln in linksmatches]
lnkmap = list()
count = 0
for l in links:
count += 1
m = re.fullmatch(lnkfrmt, l).groups()
lid = (l, "{} [{}]".format(m[0], count), "[{}] {}".format(count, m[1]))
lnkmap.append(lid)
for ltup in lnkmap:
thetext = thetext.replace(ltup[0], ltup[1])
count += 1
def replace_topheader(m):
h = m.groups()[0]
return "{}\n{}\n".format(h, len(h)*"=")
def replace_subheader(m):
h = m.groups()[0]
return "{}\n{}\n".format(h, len(h)*"-")
thetext = re.sub(topptrn, replace_topheader, thetext)
thetext = re.sub(subptrn, replace_subheader, thetext)
thetext = thetext.replace("_", "")
thetext = re.sub(r"^\s*$", "", thetext)
thetext = re.sub(r"\n{2,}", "\n\n", thetext, flags=re.MULTILINE)
lines = thetext.splitlines()
justified = list()
for l in lines:
x = 0
if l.startswith("*"):
x = 1
elif l.startswith(" *"):
x = 2
elif l.startswith(" *"):
x = 3
if len(l) < 2:
justified.append(l)
else:
l = textwrap.wrap(l, MAX_WIDTH, initial_indent="", subsequent_indent=" "*x, break_long_words=False, drop_whitespace=True, tabsize=2)
justified.extend(l)
thetext = "\n".join(justified)
thetext = thetext + "\n\n\n" + "\n".join([lt[2] for lt in lnkmap])
print(thetext)