@alcinnz@floss.social
@alcinnz@floss.social avatar

alcinnz

@alcinnz@floss.social

A browser developer posting mostly about how free software projects work, and occasionally about climate change.

Though I do enjoy german board games given an opponent.

Pronouns: he/him

This profile is from a federated server and may be incomplete. Browse more on the original instance.

alcinnz, to random
@alcinnz@floss.social avatar

I figure RISC32imv running at multiple megahertz would be plenty for decent realtime audio & graphics. Without any external audio & graphics cards! Though the V extension standardizes 128bit vectors, not 32bit like we minimally need.

Meanwhile early home computers are prized for how simple & understandable their OSs are.

Who can paint me a picture of bringing that appeal to risc32imv?

Abstractions might you want over an audio queue & framebuffer?

Programming language? Input? Simplifications?

alcinnz,
@alcinnz@floss.social avatar

@phryk Judging by prior art I'd theorize that the risc32imv alone at multi-megahertz might not be able to handle vector & 3D graphics in realtime, but if the code's optimized enough it could handle smaller scenes!

Might want to throw in the F or D extension...

alcinnz,
@alcinnz@floss.social avatar

@phryk Certainly it'd be able to run Quake!

alcinnz,
@alcinnz@floss.social avatar

@phryk As for audio: I specifically stated multi-megahertz (low ball figure) so it has time to filter the audio as it outputs it!

alcinnz,
@alcinnz@floss.social avatar

@phryk The V extension gives a free alpha-channel alongside RGB...

alcinnz,
@alcinnz@floss.social avatar

So far I heard a desire for 3D vector graphics (like in 80s/90s scifi; should be negligibly any harder 2D; from @phryk), audio filtering, making the abstractions optional, & an interpreted language like BASIC. (@millihertz)

I see mixed opinions (@vertigo) over whether CPU should generate the raw wire signal, or if that should be buffered in RAM. As a non-masochist not nostalgic for C64... I have an opinion...
Is it feasible to have a full MBs-large framebuffer with consistent timing?

1'/1.5'

alcinnz, (edited )
@alcinnz@floss.social avatar

Now I'm wondering if I should explore implementing a risc32fimv to run a UXN/Varvara simulator & Love2D (extended SDL2 bindings for Lua) game engine? Once I've finished my hardware-browser hypothetical, which shouldn't be much longer...

I'll list it as an option when I poll "what next?"

1.5'/1.5'!

alcinnz, to random
@alcinnz@floss.social avatar

Thanks to @jollyrogue for pointing me towards BeFS, for me to link to as prior art for how'd handle filesystems in my hypothetical OS. Wikipedia provided this great link: https://arstechnica.com/information-technology/2018/07/the-beos-filesystem/

Thanks @mathew for pointing me towards MailHandler & MailDir++!
https://rand-mh.sourceforge.io/book/overall/hiofmh.html
https://doc.dovecot.org/admin_manual/mailbox_formats/maildir/

Thanks @jollyrogue for linking to JMAP.
https://jmap.io/

More acknowledgements coming tomorrow, as I incorporate these links into my text!

alcinnz, to random
@alcinnz@floss.social avatar

LibPoppler ships a vendored vector graphics library "Splash" as an option for rendering PDFs to images. I'll briefly describe it this morning!

It includes a suite of classes for rendering fonts, consisting of little more than accessors. Loaded using FreeType (via wrappers) with caching, then matrix-transformed.

There's an array of path points with corresponding flags & "hints" (for recovering from low-res displays) arrays. Has methods for encoding common curves into these arrays.

1/3?

alcinnz,
@alcinnz@floss.social avatar

Splash implements microoptimized math routines.

Regarding rasterizing glyphs from a font, FreeType is hooked up to Splash's path-building methods.

There's "Pattern" subclasses for computing the colour at a given pixel.

There's a linked stack of drawing state, closely resembling the one Poppler reimplemented for itself.

There's a scanline algorithm implemented for intersecting geometries, thus implementing clipping, as managed by a seperate class. Taking shortcuts for rectangles.

2/3?

alcinnz,
@alcinnz@floss.social avatar

A "Screen" class constructs initial matrices.

Bitmaps (of which there's 2 classes) are 2D-sized byte arrays. Possibly with additional colour metadata. Most of the logic here is involved in outputting in various file formats, some of which utilize 3rd-party libs for compression.

There's a class interpolating curves to produce straight line segments.

Various trivial colour maths routines are provided.

But most of the rasterization logic is in a single class named for this library: Splash.
3/4!

alcinnz,
@alcinnz@floss.social avatar

Splash's central class tracks various colour-blending options, a target bitmap, linked-stack state (to which it proxies accessors), an anti-aliasing bitmap, anti-aliasing Y coord, an alpha bitmap with coords, anti-aliasing coordinate array for anti-aliasing "gammas", min-line-width, a thin-line mode, whether all or some of the path was clipped away, & bitflags for: anti-aliasing, shading, & debugging.

Internally it is pipelines upon 2D slices of the image, with colourspace metadata.

4/5!!

alcinnz,
@alcinnz@floss.social avatar

Results from those pipelines are written into the bitmap at given coords in appropriate encoding.

Antialiasing is done by rendering to a higher resolution & subsampling. With tweaked clipping.

Clearing the canvas is done via memset(), ensuring correct colour encoding.

Stroking a path involves matrix-transforming & interpolating curves on said path, splitting it according to the dash pattern (if any), & is either directly rasterized by split into "spans" or is converted into a fill 1st.

5/5.5

alcinnz,
@alcinnz@floss.social avatar

Min/max coords can be taken to compute a bbox.

After applying hints & taking fast paths... Stroking a path involves lowering it to line segments & clipping it retrieving the bbox, then using that same scanline algorithm to split the path into scanlines our pipeline infrastructure can rasterize. With or without antialiasing.

There's a method for matrix-transformed clipping tests, & others for different fills. One matrix-transforms or scales masks.

Fastpath for transformed image blitting.

6/6!

alcinnz, to random
@alcinnz@floss.social avatar

Design Tokens to CSS - Saneef Ansari:
https://tokens2css.nanools.com/

alcinnz, to random
@alcinnz@floss.social avatar

Single points of failure - Cory Dransfeldt:
https://feedpress.me/link/23795/16673334/single-points-of-failure

alcinnz, to random
@alcinnz@floss.social avatar

Oddly simple GUI programs - Simon Safar:
https://simonsafar.com/2024/win32_lights/

CW: Discusses Window APIs.

alcinnz, to random
@alcinnz@floss.social avatar

The kitchen s(l)ink post - Manuel Moreale:
https://manuelmoreale.com/@/page/QW85u7f4HaqBtm0R

Some good & familiar links here!

I haven't previously shared...

Woodworking as an escape from the absurdity of software - Alin Panaitiu:
https://alinpanaitiu.com/blog/woodworking-escape-from-software-absurdity/

alcinnz, to random
@alcinnz@floss.social avatar

This morning I'm skimming over the rest of LibPopplers core library & describing what I missed in using the pdftohtml command as a guide in studying it.

Which includes:

  • Parsed & binary searched Unicode Mapping tables, used in various Output Devs & the Global Params.
  • Various dataheaders, especially related to Unicode & builtin fonts. May be paired with lookup routines.
  • Convert between UTF8, UTF16, & UCS4.
  • UTF8-handling utils.
  • Parsed viewer preferences.

1/2?

alcinnz,
@alcinnz@floss.social avatar
  • Parsed sounds; used by links, annotations, & embedding frameworks.
  • Stream base-class & various subclasses.
  • Catalogs include a dynamically-typed tree structure.
  • An OutputDev which extracts rearranged & decoded text from a PDF file, much harder than it needs to be!
  • Key-value caches used in graphics & cross-reference.
  • An OutputDev which strips away degenerate PDF data.
  • An OutputDev outputting PostScript files utilizing an extra prolog.

2/3!

alcinnz,
@alcinnz@floss.social avatar
  • Parsed parameters for media playback, used by internal links.
  • Parsed PageTransitions, called by embedders.
  • Parsed Movies & their activation parameters, called by embedders.
  • Lookup character names, called by Global Parameters.
  • Stream subclasses to help decode JPEG images.
  • Log info on link-triggered JS.
  • An OutputDev extracting your annotations.
  • Utils for embedding images, used by the PDFDoc class itself.
  • Decode compact arithmetic instructions, used by JPG decoding.

3/4!!

alcinnz,
@alcinnz@floss.social avatar
  • Python script for generating Unicode dataheaders.
  • General logic for parsing out files (fonts, images, video, audio) embedded in the PDF)
  • Filepath parsing.
  • ZLib compression, used by PostScript & the PDF doc itself. With a Stream subclass.
  • Parsed FontInfo, used by Text Output & the global params.
  • Loading PDFs via LibCURL
  • Reading & writing dates.
  • Discrete Cosine Transformation streams.
  • Hashmaps & arrays.
  • "Distinguished name" parsing, used by cryptography.

4/4.5!!

alcinnz,
@alcinnz@floss.social avatar
  • Error reporting.
  • Gathering font metrics, used by Forms.
  • Parsing char maps; used by graphics, global params, & text extraction.
  • An Output Dev for computing the bbox.
  • OutputDev hooking LibPoppler up to LibCairo Vector Graphics, with box rescaling util.

And I think that pretty much covers everything else in LibPoppler's core library!

4.5/4.5! Fin for today! Tomorrow: LibSplash! Amongst its vendored libs.

alcinnz, to random
@alcinnz@floss.social avatar

Finished skimming OpenSSL, I don't see anything else in it I want to study in-depth!

Downloading kmod...

alcinnz, to random
@alcinnz@floss.social avatar

Can you detect overflow with CSS? - "The Cascade":
https://www.csscade.com/can-you-detect-overflow-with-css

  • All
  • Subscribed
  • Moderated
  • Favorites
  • anitta
  • mdbf
  • thenastyranch
  • Youngstown
  • hgfsjryuu7
  • slotface
  • rosin
  • ngwrru68w68
  • InstantRegret
  • kavyap
  • osvaldo12
  • everett
  • DreamBathrooms
  • PowerRangers
  • normalnudes
  • magazineikmin
  • Durango
  • khanakhh
  • tacticalgear
  • vwfavf
  • ethstaker
  • GTA5RPClips
  • modclub
  • cubers
  • tester
  • cisconetworking
  • Leos
  • provamag3
  • All magazines