Skip to content

Commit fd9d454

Browse files
committed
Documentation updates.
1 parent b407690 commit fd9d454

2 files changed

Lines changed: 8 additions & 0 deletions

File tree

src/gameobjects/BitmapData.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -623,6 +623,8 @@ Phaser.BitmapData.prototype = {
623623

624624
/**
625625
* Get the color of a specific pixel in the context into a color object.
626+
* If you have drawn anything to the BitmapData since it was created you must call BitmapData.update to refresh the array buffer,
627+
* otherwise this may return out of date color values, or worse - throw a run-time error as it tries to access an array element that doesn't exist.
626628
*
627629
* @method Phaser.BitmapData#getPixel
628630
* @param {number} x - The x coordinate of the pixel to be set. Must lay within the dimensions of this BitmapData.
@@ -655,6 +657,8 @@ Phaser.BitmapData.prototype = {
655657

656658
/**
657659
* Get the color of a specific pixel including its alpha value.
660+
* If you have drawn anything to the BitmapData since it was created you must call BitmapData.update to refresh the array buffer,
661+
* otherwise this may return out of date color values, or worse - throw a run-time error as it tries to access an array element that doesn't exist.
658662
* Note that on little-endian systems the format is 0xAABBGGRR and on big-endian the format is 0xRRGGBBAA.
659663
*
660664
* @method Phaser.BitmapData#getPixel32
@@ -673,6 +677,8 @@ Phaser.BitmapData.prototype = {
673677

674678
/**
675679
* Get the color of a specific pixel including its alpha value as a color object containing r,g,b,a and rgba properties.
680+
* If you have drawn anything to the BitmapData since it was created you must call BitmapData.update to refresh the array buffer,
681+
* otherwise this may return out of date color values, or worse - throw a run-time error as it tries to access an array element that doesn't exist.
676682
*
677683
* @method Phaser.BitmapData#getPixelRGB
678684
* @param {number} x - The x coordinate of the pixel to be set. Must lay within the dimensions of this BitmapData.

src/sound/SoundManager.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
* Sound Manager constructor.
99
* The Sound Manager is responsible for playing back audio via either the Legacy HTML Audio tag or via Web Audio if the browser supports it.
1010
* Note: On Firefox 25+ on Linux if you have media.gstreamer disabled in about:config then it cannot play back mp3 or m4a files.
11+
* The audio file type and the encoding of those files are extremely important. Not all browsers can play all audio formats.
12+
* There is a good guide to what's supported here: http://hpr.dogphilosophy.net/test/
1113
*
1214
* @class Phaser.SoundManager
1315
* @classdesc Phaser Sound Manager.

0 commit comments

Comments
 (0)