Removed Panner setVelocity in Chrome and Emscripten

In Chrome 55+ the function setVelocity has been removed. If your C++ game depends on OpenAL and somewhere you call:

alSource3f(mAlSourceId, AL_VELOCITY,

alSource3f(mAlSourceId, AL_SOURCE_RELATIVE, ...

Then you should either remove those calls, but if your game depends on AL_SOURCE_RELATIVE and you cannot remove it, then it’s required to add a simple snipped to your HTML page:

 

It’s required due an underlying implementation that sets velocity while you call set source relative.

 


Use Docker image directly under Windows 10

Windows Subsystem for Linux allows to run Linux binaries directly under Windows. Next logical step might be to try to install Docker on the Linux, and then run images.

It might work, never tried. But, I’ve discovered (quite late – I have to admit) a way to ‘mount’ directly any Docker image as a subsystem for Windows 10.

What is needed:


Unique identified of any Type in C++

Simple and useful snippet that helps to make an unique identifier for any type in C++.

It uses a fact that function static member of a function is a part of template installation, hence it contains own, unique address.

 

 

 


Configure ConEmu and clink to show git branch

This is an extension to http://asria.pl/customize-conemu/ but int this case in a form of a tutorial / guideline that will help me (and maybe you) to mirror this setup.

The description shows how to configure conemu and clink, and display name of current branch:

 


WebAssembly preview support in every major browser

Today it was announced that Mozilla, Microsoft, Google Chrome and Apple Webkit have got a support for binary format for JavaScript.

What does it mean for JavaScript developers? Nothing probably, they will continue doing JavaScript programming until some tool will compile plain JavaScript (or even ASM.JS subset) to binary format.

So, who is a target for this technology?

Mostly C++/C# developers. WebAssembly is a successor of ASM.JS that cooperates with Emscripten SDK. What is super important, it removes majority of constrains like:

  • i64 emulation: In plain JavaScript has no native representation of 64 bit integers, hence such common type has to be emulated. Quick benchmark made by Mozilla shows, that emulation is 8x slower than native solution. In WebAssembly it’s only 1.13x slower.
  • Contiguous HEAP: ASM.JS requires an emulate HEAP what is basically an array that stores what normally would be stored in free memory. Decent game requires to have about 512MB of HEAP. Problem with this is that it’s hard for browser to find free, not fragmented memory that can holds it.
  • Debugging: Debugging ASM.JS code that has 10MB in size optimal version, or 100MB of JS code of debug version can kill every browser, and stepping through breakpoints takes a few seconds.

 

More info: http://webassembly.org/roadmap/

 


Use Docker for Emscripten – Usage

logo &switch_logo

Prelude

Docker based solution was a test how Emscripten SDK can be simplified for usage on Linux and especially how it could be used in CI in non-intrusive way.

Links


Windows 10 support of Hi-DPI and Low-DPI displays

Although Windows 10 has significantly improved support for high density displays I do have some strange issue, that I cannot confirm it’s a bug in my setup, or this is something not fixed yet.

 


Fetch all images from devopreactions.tumblr.com

http://65.media.tumblr.com/avatar_3c617802d89c_64.png

 

 

At some point I had to create a presentation about some technical stuff. Challenge was that, course what I had host takes 2 days (2x8h).

It’s easy to make material boring, especially that was a technical presentation.

Instead of making course in typical way I decided to put text on slide in very very required situation. In each case I tried to use a white board or just regular talk  and explanation. So I end up with Power Point presentation with 140 pages, where 90% are images and 35% are gifs.


Customize ConEmu

I’ve started to look after good console under Windows after I’ve tried console on MacOS and Linux (Ubuntu).

2015-08-30_15-34-36


Problem with alpha in BitmapData / PNG

BitmapData doesn’t store each data what we would like to store.

If BitmapData contains transparency (from constructor argument, or loaded by Loader). It is possible to store R,G,B information in concrete pixel only if A component is not 0. That makes some problem with right texture support for Stage3D