October 2022 Release

changes on the meta-level

New Toys To Play With...

...and a lot of smaller changes, improvements and bugfixes come with the third cables.gl-release of 2022.

This post will lead you through all the changes and improvements that we added to cables in the last few weeks.
If you just want the tl;dr, check out the changelog or watch our "Release Chat" on YouTube.

We'd love to hear your feedback, let us know!

Virtual Worlds With WebXR/VR

We picked up on where we left in the last release and moved our beloved example room to VR. WebXR-VR is coming along quite nicely these days and we updated our experimental VR ops and made them work on many devices.

We got ourselves some headsets, jumped in on the task and added two new Ops to the cables library: WebXrVr and WebXrVrController.

Once you put the WebXr.Vr-Op into your patch and open it on a capable device, you will be presented with a "headset icon" on top of your patch. Click it and you can dive right in!

With just these two ops, you to add VR capabilities and controls to your patches easily. Check out the examples and see how easy it is to experience your patches in Virtual Reality.

As said, this is the very first version of WebXr in cables and we would love to hear from you. If you have any feedback on devices, features or workflow, please let us know.

It works great on devices like Quest 2, HoloLens or many Android phones. Without a headset, you can use this handy extension for Chrome and Firefox. Try it:

Managing Collaboration

Collaborating with people is a huge part of how we think cables should work. Be it via public patches, remixing, sharing or working together on private projects.

We now introduce better control of who can see, play around or edit a patch.

This is explained in full detail in the documentation. Here is a quick rundown:

Request Access
Any team member, or user with a secret link will see a "request access" button on the patchpage. Click it to let the owner of the patch know, that you want to help them work on the patch.

For example: You can safely ask for help in the forums using a secret link and give read only access to people that offer help.

To not have you flooded with a lot of requests, this button is not shown for public patches.
Grant Permissions
The owner of the patch will see new requests on their invite page, and also be notified with a red bubble the next time they open cables.gl.

It's now up to them to decide on the level of access. In a nutshell: "Full Access" allows everything, "Read Only" allows to play around but never save the patch.

We also added this functionality to invites, so whenver you want to share a patch with someone you can now decide if they should be able to make changes to your patch.
Collaboration Overview
Working with collaborators has become more centralized. You can now decide on the level of access even after accepting requests or sending out invitations.

Simply open the "Collaboration"-Tab in the settings of any patch and invite new users, see pending requests or change the permissions of current collaborators. Even for patches created before this update!

Easier Life In The Editor

Making your patching-experience a better one, improving on workflows and making it easier to keep your patches clean and tidy is one of the most important goals of every release.

Let's see what we came up with this time to make the life of patching even more enjoyable.

Do you also like your patches cleanly organized and aligned in a aestetically pleasing manner? Then this new feature will make you smile.

The editor will now show a vertical line when dragging ops around. You will see when they "snap" to other ops that are on the same position, vertically. No more excuses for crooked cables!
We added more context based suggestions for fitting ops. So now you have a shortcut to create Texture-, StringEditor-, DivElement-Ops and all the fitting VizOps for the type of the port.

The opsearch dialog will now be even more clever and allow you to create and use variables or triggers to organize your patch. You can even decide if you want to set the variable directly or control setting of the variable with a trigger.
Connecting Ports
You might have encountered situations where it was very tedious to link ops to each others. Be it because of display size or input method. With the new "longpress" functionality in the editor that's a thing of the past.

To use it, click on any op and hold until a white line will appear. Now, navigate to the op you want to connect and select it. You will be given the known selection of fitting ports to choose from.

We enabled both of these features in the editor, they can easily be turned off in your editor preferences.
Quick Math
All the simple math ops to work on numbers in cables are now quickly accessible via shortcuts.

Press escape to open the opsearch dialog. Then simply enter +, -, * or / to add the appropriate op to your patch.
You don't even have to press enter anymore!

Shiny New Toys And Some Old Friends

To facilitate for the (pretty common) task of playing media files, or even controlling the cables timeline, we created "PlayerControlPanel". The op gives you a simple UI to work with AudioBufferPlayer, TimelinePlayer or anything else that somehow works with a "current time". Check the example for a timeline-based audioplayer that allows for skipping and navigating in the track!

When debugging the state of your patches, all the Viz-Ops come in handy. If you have to deal with text, or long strings in general.

VizStringLong will now show you all the content you need to get an idea on what's going on.
This new op will make getting an overview of your arrays a breeze. Connect any array with numerical values to it an it will show the distribution of it's contents as a piechart.

If you need the values named, add an array of strings to the op to have your piechart labeled with.
GradientTexture received a trigger port that allows you to randomize the colors it outputs.

The number of points you gradient will have is still up to you to decide. You can manually trigger and refine the generated gradient or just let it be completely random by triggering it, say, at a certain Interval.
Pose Tracking Mask
With a small update to MpPoseTracking you now can work with the segmentation mask provided by the media pipe library and hand it over to other ops.

The most simple example would be to mask the background of a webcam image, but we are sure you will come up with much more creative uses for this feature.
FreezeMeshes lets you combine multiple meshes into one geometry, to optimize performance.

With GeometryToObj you can generate an .obj file from a geometry. For example, you can import your geometries in any 3d software (like blender).

More Ammo For Your Patches

With the release back in June we introduced a new way of working with physics in cables. ammo.js.

We got a lot of feedback on that and also spent some more time on our own to see how it performs. This resulted in quite some changes, additions and improvements to the ops that were introduced almost four months ago.

AmmoBody got an option to "be" a triangle mesh, it now can work with an array as an input to create multiple bodies at once. To optimize performance when using physics in only parts of your project AmmoWorld now cleans up all the bodies internally, when set to inactive via an input boolean. You will also find a new output port for all collisions that currently happen in the world.

AmmoCollision, for that matter, now can filter collisions more fine-grained. You can match the name of either body of the collision using "exact", "startswith" or "contains" matching. So "ball collides with any wall" is possible and now also works well with AmmoEmitter. Stick all of this together with AmmoRaycast, now outputting hit positions.

Show us how you create games with cables!

Things That Also Happened

For a complete overview on what changed, head over to the changelog, it is quite the read.

If you are still not done with reading, check out our updates to the documentation. We added a new section on coding your own VizOps, as already mentioned there is a whole write-up of the (new) permission system to patches and we moved the section on embedding exported patches into your website to a more prominent place.

Talking about exported patches... The exe export has been changed to not rely on github anymore. It is a lot easier to export executables of your patches now! And for folks working with the likes of react/Vue or any other framework or platform that does not handle subdirectories (well), every export now comes with a "Export without subdirectories" options. This puts javascript and assets alongside the exported index.html.

And last, but not least, we added some cool new projects to our "hall of fame". Check out made with cables to see some impressive "real world" projects that were made with cables.

Thanks to everyone who contributed to this awesome release! As always we'd love to hear some feedback from you, be it on social media, on discord or on github discussions.

Most importantly: Have fun with all of this!

Team Cables