Closed IceHacks closed 5 years ago
I have the same problem
https://github.com/chearon/node-canvas-prebuilt/releases/download/v1.6.11/canvas-prebuilt-v1.6.11-node-v67-win32-x64.tar.gz no more available
Well I think the solution is to fork this and replace canvas-prebuilt
with canvas
. However I don't know :) I really want to render on the server side.
@IceHacks or @olegdraganchuk
is the problem still existing? that might've been a problem with build on canvas-prebuilt repository
$ yarn install
yarn install v1.12.3
info No lockfile found.
[1/4] Resolving packages...
[2/4] Fetching packages...
[3/4] Linking dependencies...
[4/4] Building fresh packages...
success Saved lockfile.
Done in 19.55s.
jpietal@zenmonk:~/projects/pixi-shim$ yarn test
yarn run v1.12.3
$ node test.js
pixi-shim: polyfill dom
pixi-shim: load pixijs
pixi-shim: initialized in: 448.725ms
{ Application:
{ [Function: Application]
registerPlugin: [Function: registerPlugin],
_plugins: [ [Object], [Object], [Object] ] },
systems:
{ FilterSystem: [Function: FilterSystem],
BatchSystem: [Function: BatchSystem],
ContextSystem: [Function: ContextSystem],
FramebufferSystem: [Function: FramebufferSystem],
GeometrySystem: [Function: GeometrySystem],
MaskSystem: [Function: MaskSystem],
StencilSystem: [Function: StencilSystem],
ProjectionSystem: [Function: ProjectionSystem],
RenderTextureSystem: [Function: RenderTextureSystem],
ShaderSystem: [Function: ShaderSystem],
StateSystem: { [Function: StateSystem] checkBlendMode: [Function: checkBlendMode] },
TextureGCSystem: [Function: TextureGCSystem],
TextureSystem: [Function: TextureSystem] },
resources:
{ INSTALLED:
[ [Function: ImageResource],
[Object],
[Object],
[Object],
[Object],
[Object],
[Function: ArrayResource] ],
autoDetectResource: [Function: autoDetectResource],
ArrayResource: [Function: ArrayResource],
BufferResource: { [Function: BufferResource] test: [Function: test] },
CanvasResource: { [Function: CanvasResource] test: [Function: test] },
CubeResource: { [Function: CubeResource] SIDES: 6 },
ImageResource: [Function: ImageResource],
SVGResource:
{ [Function: SVGResource]
getSize: [Function: getSize],
test: [Function: test],
SVG_SIZE: /<svg[^>]*(?:\s(width|height)=('|")(\d*(?:\.\d+)?)(?:px)?('|"))[^>]*(?:\s(width|height)=('|")(\d*(?:\.\d+)?)(?:px)?('|"))[^>]*>/i },
VideoResource: { [Function: VideoResource] test: [Function: test], TYPES: [Array] },
Resource: [Function: Resource],
BaseImageResource: { [Function: BaseImageResource] crossOrigin: [Function: crossOrigin] } },
System: [Function: System],
Renderer:
{ [Function: Renderer]
registerPlugin: [Function: registerPlugin],
__plugins:
{ accessibility: [Function: AccessibilityManager],
extract: [Function: Extract],
interaction: [Function: InteractionManager],
particle: [Function: ParticleRenderer],
prepare: [Function: Prepare],
batch: [Function: BatchRenderer],
tilingSprite: [Function: TilingSpriteRenderer] } },
AbstractRenderer: [Function: AbstractRenderer],
Framebuffer: [Function: Framebuffer],
CubeTexture: { [Function: CubeTexture] from: [Function: from] },
BaseTexture:
{ [Function: BaseTexture]
from: [Function: from],
fromBuffer: [Function: fromBuffer],
addToCache: [Function: addToCache],
removeFromCache: [Function: removeFromCache] },
GLTexture:
{ [Function: BaseTexture]
from: [Function: from],
fromBuffer: [Function: fromBuffer],
addToCache: [Function: addToCache],
removeFromCache: [Function: removeFromCache] },
Texture:
{ [Function: Texture]
from: [Function: from],
fromBuffer: [Function: fromBuffer],
fromLoader: [Function: fromLoader],
addToCache: [Function: addToCache],
removeFromCache: [Function: removeFromCache],
EMPTY:
Texture {
_events: {},
_eventsCount: 0,
noFrame: true,
baseTexture: [Object],
_frame: [Object],
trim: undefined,
valid: false,
requiresUpdate: false,
_uvs: [Object],
uvMatrix: null,
orig: [Object],
_rotate: 0,
defaultAnchor: [Object],
_updateID: 0,
textureCacheIds: [],
destroy: [Function: _emptyDestroy],
on: [Function: _emptyOn],
once: [Function: _emptyOnce],
emit: [Function: _emptyEmit] },
WHITE:
Texture {
_events: {},
_eventsCount: 0,
noFrame: false,
baseTexture: [Object],
_frame: [Object],
trim: undefined,
valid: true,
requiresUpdate: false,
_uvs: [Object],
uvMatrix: null,
orig: [Object],
_rotate: 0,
_updateID: 0,
defaultAnchor: [Object],
textureCacheIds: [],
destroy: [Function: _emptyDestroy],
on: [Function: _emptyOn],
once: [Function: _emptyOnce],
emit: [Function: _emptyEmit] } },
TextureMatrix: [Function: TextureMatrix],
RenderTexture: { [Function: RenderTexture] create: [Function: create] },
BaseRenderTexture: [Function: BaseRenderTexture],
TextureUvs: [Function: TextureUvs],
State: { [Function: State] for2d: [Function: for2d] },
ObjectRenderer: [Function: ObjectRenderer],
BatchRenderer: [Function: BatchRenderer],
BatchGeometry: [Function: BatchGeometry],
BatchDrawCall: [Function: BatchDrawCall],
generateMultiTextureShader: [Function: generateMultiTextureShader],
Quad: [Function: Quad],
QuadUv: [Function: QuadUv],
checkMaxIfStatementsInShader: [Function: checkMaxIfStatementsInShader],
Shader: { [Function: Shader] from: [Function: from] },
Program: { [Function: Program] from: [Function: from] },
GLProgram: [Function: GLProgram],
UniformGroup: { [Function: UniformGroup] from: [Function: from] },
SpriteMaskFilter: [Function: SpriteMaskFilter],
Filter: { [Function: Filter] SOURCE_KEY_MAP: {} },
Attribute: { [Function: Attribute] from: [Function: from] },
Buffer: { [Function: Buffer] from: [Function: from] },
Geometry: { [Function: Geometry] merge: [Function: merge] },
LoaderResource:
{ [Function: Resource]
setExtensionLoadType: [Function: setExtensionLoadType],
setExtensionXhrType: [Function: setExtensionXhrType],
STATUS_FLAGS: { NONE: 0, DATA_URL: 1, COMPLETE: 2, LOADING: 4 },
TYPE:
{ UNKNOWN: 0,
JSON: 1,
XML: 2,
IMAGE: 3,
AUDIO: 4,
VIDEO: 5,
TEXT: 6 },
LOAD_TYPE: { XHR: 1, IMAGE: 2, AUDIO: 3, VIDEO: 4 },
XHR_RESPONSE_TYPE:
{ DEFAULT: 'text',
BUFFER: 'arraybuffer',
BLOB: 'blob',
DOCUMENT: 'document',
JSON: 'json',
TEXT: 'text' },
_loadTypeMap:
{ gif: 2,
png: 2,
bmp: 2,
jpg: 2,
jpeg: 2,
tif: 2,
tiff: 2,
webp: 2,
tga: 2,
svg: 2,
'svg+xml': 2,
mp3: 3,
ogg: 3,
wav: 3,
mp4: 4,
webm: 4 },
_xhrTypeMap:
{ xhtml: 'document',
html: 'document',
htm: 'document',
xml: 'document',
tmx: 'document',
svg: 'document',
tsx: 'document',
gif: 'blob',
png: 'blob',
bmp: 'blob',
jpg: 'blob',
jpeg: 'blob',
tif: 'blob',
tiff: 'blob',
webp: 'blob',
tga: 'blob',
json: 'json',
text: 'text',
txt: 'text',
ttf: 'arraybuffer',
otf: 'arraybuffer',
fnt: 'document' },
EMPTY_GIF: 'data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw==' },
Loader:
{ [Function: Loader]
_plugins: [ [Object], [Object], [Object], [Object] ],
registerPlugin: [Function: registerPlugin] },
TextureLoader: { [Function: TextureLoader] use: [Function: use] },
AppLoaderPlugin: { [Function: AppLoaderPlugin] init: [Function: init], destroy: [Function: destroy] },
ParticleContainer: [Function: ParticleContainer],
ParticleRenderer: [Function: ParticleRenderer],
Spritesheet: [Function: Spritesheet],
SpritesheetLoader:
{ [Function: SpritesheetLoader]
use: [Function: use],
getResourcePath: [Function: getResourcePath] },
TilingSprite:
{ [Function: TilingSprite]
from: [Function: from],
fromFrame: [Function: fromFrame],
fromImage: [Function: fromImage] },
TilingSpriteRenderer: [Function: TilingSpriteRenderer],
BitmapText: { [Function: BitmapText] registerFont: [Function: registerFont], fonts: {} },
BitmapFontLoader:
{ [Function: BitmapFontLoader]
parse: [Function: parse],
add: [Function: add],
dirname: [Function: dirname],
use: [Function: use] },
Ticker: [Function: Ticker],
TickerPlugin: { [Function: TickerPlugin] init: [Function: init], destroy: [Function: destroy] },
UPDATE_PRIORITY: { INTERACTION: 50, HIGH: 25, NORMAL: 0, LOW: -25, UTILITY: -50 },
ENV: { WEBGL_LEGACY: 0, WEBGL: 1, WEBGL2: 2 },
RENDERER_TYPE: { UNKNOWN: 0, WEBGL: 1, CANVAS: 2 },
BLEND_MODES:
{ NORMAL: 0,
ADD: 1,
MULTIPLY: 2,
SCREEN: 3,
OVERLAY: 4,
DARKEN: 5,
LIGHTEN: 6,
COLOR_DODGE: 7,
COLOR_BURN: 8,
HARD_LIGHT: 9,
SOFT_LIGHT: 10,
DIFFERENCE: 11,
EXCLUSION: 12,
HUE: 13,
SATURATION: 14,
COLOR: 15,
LUMINOSITY: 16,
NORMAL_NPM: 17,
ADD_NPM: 18,
SCREEN_NPM: 19,
NONE: 20,
SRC_OVER: 0,
SRC_IN: 21,
SRC_OUT: 22,
SRC_ATOP: 23,
DST_OVER: 24,
DST_IN: 25,
DST_OUT: 26,
DST_ATOP: 27,
ERASE: 26,
SUBTRACT: 28 },
DRAW_MODES:
{ POINTS: 0,
LINES: 1,
LINE_LOOP: 2,
LINE_STRIP: 3,
TRIANGLES: 4,
TRIANGLE_STRIP: 5,
TRIANGLE_FAN: 6 },
FORMATS:
{ RGBA: 6408,
RGB: 6407,
ALPHA: 6406,
LUMINANCE: 6409,
LUMINANCE_ALPHA: 6410,
DEPTH_COMPONENT: 6402,
DEPTH_STENCIL: 34041 },
TARGETS:
{ TEXTURE_2D: 3553,
TEXTURE_CUBE_MAP: 34067,
TEXTURE_2D_ARRAY: 35866,
TEXTURE_CUBE_MAP_POSITIVE_X: 34069,
TEXTURE_CUBE_MAP_NEGATIVE_X: 34070,
TEXTURE_CUBE_MAP_POSITIVE_Y: 34071,
TEXTURE_CUBE_MAP_NEGATIVE_Y: 34072,
TEXTURE_CUBE_MAP_POSITIVE_Z: 34073,
TEXTURE_CUBE_MAP_NEGATIVE_Z: 34074 },
TYPES:
{ UNSIGNED_BYTE: 5121,
UNSIGNED_SHORT: 5123,
UNSIGNED_SHORT_5_6_5: 33635,
UNSIGNED_SHORT_4_4_4_4: 32819,
UNSIGNED_SHORT_5_5_5_1: 32820,
FLOAT: 5126,
HALF_FLOAT: 36193 },
SCALE_MODES: { LINEAR: 1, NEAREST: 0 },
WRAP_MODES: { CLAMP: 33071, REPEAT: 10497, MIRRORED_REPEAT: 33648 },
MIPMAP_MODES: { OFF: 0, POW2: 1, ON: 2 },
GC_MODES: { AUTO: 0, MANUAL: 1 },
PRECISION: { LOW: 'lowp', MEDIUM: 'mediump', HIGH: 'highp' },
Bounds: [Function: Bounds],
DisplayObject: [Function: DisplayObject],
Container: [Function: Container],
Graphics: { [Function: Graphics] _TEMP_POINT: Point { x: 0, y: 0 } },
GraphicsData: [Function: GraphicsData],
GraphicsGeometry: { [Function: GraphicsGeometry] BATCHABLE_SIZE: 100 },
GRAPHICS_CURVES:
{ adaptive: true,
maxLength: 10,
minSegments: 8,
maxSegments: 2048,
_segmentsCount: [Function: _segmentsCount] },
Point: [Function: Point],
ObservablePoint: [Function: ObservablePoint],
Matrix: [Function: Matrix],
GroupD8:
{ E: 0,
SE: 1,
S: 2,
SW: 3,
W: 4,
NW: 5,
N: 6,
NE: 7,
MIRROR_VERTICAL: 8,
MIRROR_HORIZONTAL: 12,
uX: [Function: uX],
uY: [Function: uY],
vX: [Function: vX],
vY: [Function: vY],
inv: [Function: inv],
add: [Function: add],
sub: [Function: sub],
rotate180: [Function: rotate180],
isVertical: [Function: isVertical],
byDirection: [Function: byDirection],
matrixAppendRotationInv: [Function: matrixAppendRotationInv] },
Transform:
{ [Function: Transform]
IDENTITY:
Transform {
worldTransform: [Object],
localTransform: [Object],
position: [Object],
scale: [Object],
pivot: [Object],
skew: [Object],
_rotation: 0,
_cx: 1,
_sx: 0,
_cy: 0,
_sy: 1,
_localID: 0,
_currentLocalID: 0,
_worldID: 0,
_parentID: 0 } },
Circle: [Function: Circle],
Ellipse: [Function: Ellipse],
Polygon: [Function: Polygon],
Rectangle: [Function: Rectangle],
RoundedRectangle: [Function: RoundedRectangle],
PI_2: 6.283185307179586,
RAD_TO_DEG: 57.29577951308232,
DEG_TO_RAD: 0.017453292519943295,
SHAPES: { POLY: 0, RECT: 1, CIRC: 2, ELIP: 3, RREC: 4 },
Mesh: { [Function: Mesh] BATCHABLE_SIZE: 100 },
MeshBatchUvs: [Function: MeshBatchUvs],
MeshMaterial: [Function: MeshMaterial],
MeshGeometry: [Function: MeshGeometry],
PlaneGeometry: [Function: PlaneGeometry],
RopeGeometry: [Function: RopeGeometry],
SimpleRope: [Function: SimpleRope],
SimplePlane: [Function: SimplePlane],
SimpleMesh: [Function: SimpleMesh],
NineSlicePlane: [Function: NineSlicePlane],
Sprite: { [Function: Sprite] from: [Function: from] },
AnimatedSprite:
{ [Function: AnimatedSprite]
fromFrames: [Function: fromFrames],
fromImages: [Function: fromImages] },
Text: [Function: Text],
TextStyle: [Function: TextStyle],
TextMetrics:
{ [Function: TextMetrics]
measureText: [Function: measureText],
wordWrap: [Function: wordWrap],
addLine: [Function: addLine],
getFromCache: [Function: getFromCache],
collapseSpaces: [Function: collapseSpaces],
collapseNewlines: [Function: collapseNewlines],
trimRight: [Function: trimRight],
isNewline: [Function: isNewline],
isBreakingSpace: [Function: isBreakingSpace],
tokenize: [Function: tokenize],
canBreakWords: [Function: canBreakWords],
canBreakChars: [Function: canBreakChars],
measureFont: [Function: measureFont],
clearMetrics: [Function: clearMetrics],
_canvas: HTMLCanvasElement {},
_context:
CanvasRenderingContext2D {
canvas: HTMLCanvasElement {},
createPattern: [Function],
drawImage: [Function] },
_fonts: {},
METRICS_STRING: '|Éq',
BASELINE_SYMBOL: 'M',
BASELINE_MULTIPLIER: 1.4,
_newlines: [ 10, 13 ],
_breakingSpaces:
[ 9,
32,
8192,
8193,
8194,
8195,
8196,
8197,
8198,
8200,
8201,
8202,
8287,
12288 ] },
TEXT_GRADIENT: { LINEAR_VERTICAL: 0, LINEAR_HORIZONTAL: 1 },
settings:
{ MIPMAP_TEXTURES: 1,
RESOLUTION: 1,
FILTER_RESOLUTION: 1,
SPRITE_MAX_TEXTURES: 32,
SPRITE_BATCH_SIZE: 4096,
RENDER_OPTIONS:
{ view: null,
antialias: false,
forceFXAA: false,
autoResize: false,
transparent: false,
backgroundColor: 0,
clearBeforeRender: true,
preserveDrawingBuffer: false,
width: 800,
height: 600,
legacy: false },
GC_MODE: 0,
GC_MAX_IDLE: 3600,
GC_MAX_CHECK_COUNT: 600,
WRAP_MODE: 33071,
SCALE_MODE: 1,
PRECISION_VERTEX: 'highp',
PRECISION_FRAGMENT: 'mediump',
CAN_UPLOAD_SAME_BUFFER: true,
CREATE_IMAGE_BITMAP: true,
ROUND_PIXELS: false,
RETINA_PREFIX: /@([0-9\.]+)x/,
SORTABLE_CHILDREN: false,
TARGET_FPMS: 0.06,
PREFER_ENV: 2,
UPLOADS_PER_FRAME: 4 },
accessibility:
{ accessibleTarget:
{ accessible: false,
accessibleTitle: null,
accessibleHint: null,
tabIndex: 0,
_accessibleActive: false,
_accessibleDiv: false },
AccessibilityManager: [Function: AccessibilityManager] },
extract: { Extract: [Function: Extract] },
interaction:
{ InteractionData: [Function: InteractionData],
InteractionManager: [Function: InteractionManager],
interactiveTarget:
{ interactive: false,
interactiveChildren: true,
hitArea: null,
buttonMode: [Getter/Setter],
cursor: null,
trackedPointers: [Getter],
_trackedPointers: undefined },
InteractionTrackingData: { [Function: InteractionTrackingData] FLAGS: [Object] },
InteractionEvent: [Function: InteractionEvent] },
prepare:
{ Prepare: [Function: Prepare],
BasePrepare: [Function: BasePrepare],
CountLimiter: [Function: CountLimiter],
TimeLimiter: [Function: TimeLimiter] },
utils:
{ isMobile:
{ apple: [Object],
amazon: [Object],
android: [Object],
windows: [Object],
other: [Object],
any: false,
phone: false,
tablet: false },
removeItems: [Function: removeItems],
EventEmitter: { [Function: EventEmitter] prefixed: false, EventEmitter: [Circular] },
earcut:
{ [Function: earcut]
default: [Circular],
deviation: [Function],
flatten: [Function] },
mixins:
{ mixin: [Function: mixin],
delayMixin: [Function: delayMixin],
performMixins: [Function: performMixins] },
skipHello: [Function: skipHello],
sayHello: [Function: sayHello],
isWebGLSupported: [Function: isWebGLSupported],
hex2rgb: [Function: hex2rgb],
hex2string: [Function: hex2string],
string2hex: [Function: string2hex],
rgb2hex: [Function: rgb2hex],
premultiplyBlendMode: [ [Array], [Array] ],
correctBlendMode: [Function: correctBlendMode],
premultiplyRgba: [Function: premultiplyRgba],
premultiplyTint: [Function: premultiplyTint],
premultiplyTintToRgba: [Function: premultiplyTintToRgba],
createIndicesForQuads: [Function: createIndicesForQuads],
uid: [Function: uid],
sign: [Function: sign],
nextPow2: [Function: nextPow2],
isPow2: [Function: isPow2],
log2: [Function: log2],
CanvasRenderTarget: [Function: CanvasRenderTarget],
ProgramCache: {},
TextureCache: {},
BaseTextureCache: {},
destroyTextureCache: [Function: destroyTextureCache],
clearTextureCache: [Function: clearTextureCache],
trimCanvas: [Function: trimCanvas],
decomposeDataUri: [Function: decomposeDataUri],
determineCrossOrigin: [Function: determineCrossOrigin],
getResolutionOfUrl: [Function: getResolutionOfUrl],
DATA_URI: /^\s*data:(?:([\w-]+)\/([\w+.-]+))?(?:;charset=([\w-]+))?(?:;(base64))?,(.*)/i,
deprecation: [Function: deprecation] },
VERSION: '5.0.0-rc.2',
filters:
{ AlphaFilter: [Function: AlphaFilter],
BlurFilter: [Function: BlurFilter],
BlurFilterPass: [Function: BlurFilterPass],
ColorMatrixFilter: [Function: ColorMatrixFilter],
DisplacementFilter: [Function: DisplacementFilter],
FXAAFilter: [Function: FXAAFilter],
NoiseFilter: [Function: NoiseFilter] },
useDeprecated: [Function: useDeprecated],
default: [Circular] }
Done in 0.55s.
Please run
cd node_modules/pixi-shim
npm install
npm run test
and paste the results thanks
@Prozi I'll check later
@IceHacks does this work now?
closing because I think this works as I tested and no response
The install fails when it gets a 404 for the following tarball