These are chat archives for pixijs/pixi.js

11th
Jan 2018
@R_Talon_twitter
Jan 11 2018 08:21

Hello everybody!!

I need your knowledge and wisdom. I'm doing a game with 16 languages support ( with each other japanese, chinese ). What is the best solution?

A - using BitmapText
B - Pixi Text Font
C - Another solution.

BitmapText: Atlas with all characters latin, cyrilic, chinese, japanese, etc ( problem, huge atlas )
TextFont: load a font.ttf / font.otf. The "problem" is when browser load it ( solution Font.js loader )

Is there any paper about this topic?

Thanks!!

Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 09:11
depends on how good are you with pixi and webgl, you can store characters inside different RGB channels.
that's 3 times less videomemory
but fun with renderer plugins ;)
@R_Talon_twitter
Jan 11 2018 09:33
Wow!!! is a master solution :D ahahahahaha
Mark Knol
@markknol
Jan 11 2018 09:53
I have a pixi project (banner) which is loaded in iframe with sandbox="allow-scripts" Now I got all kind of CORS errors Access to Image at 'http://localhost:7000/debug/assets/preloader/logo.png' from origin 'null' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present
I'm using Pixi v4.5.1
I tried adding { crossOrigin: "anonymous" } to my loader
this makes the application run, but no image is loaded
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 09:55
@englercj
Mark Knol
@markknol
Jan 11 2018 09:55
without this, I get DOMException: Failed to execute 'texImage2D' on 'WebGLRenderingContext':
I know the sandbox parameter is the cause, but I cannot change this, since it is requirement of the advertisement platform
I'd love some help on this if possible
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 10:04
embed logo in the source code
base64 doesnt need CORS ;)
Mark Knol
@markknol
Jan 11 2018 10:09
I have quite some images, if thats the only solution I might want to use that...
Mark Knol
@markknol
Jan 11 2018 10:47
I hope my filesize with base64 then doenst exceed the limits too
Mark Knol
@markknol
Jan 11 2018 11:08
how do you "load" a base64 image?
if I have the data somewhere
Sprite.fromImage(base64data < ?
Mark Knol
@markknol
Jan 11 2018 11:53
I inlined all images now, this works :D
Roi Peker
@roipeker
Jan 11 2018 14:03
Hello!
quick question, is my first time using pixi... I'm going through the hexi samples.
most devs are using v3 or v4?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 14:33
v4
Roi Peker
@roipeker
Jan 11 2018 15:13
the famous Ivan :) hi man
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:13
hey! ^_^
yeah, im the one on newb duty.
Roi Peker
@roipeker
Jan 11 2018 15:14
good to know!
so... if that's the case, any game engine recommendation for v4 ?
'cause hexi is for v3
and phaser as well, no ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:16
I dont remember whats hexi. Trying to access, it This page is taking way too long to load.
phaser has heavy modified v2 inside, and new phaser has their own custom renderer
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:17
but if kittykatattack wrote hexi, i think its not a problem to move it to v4
Roi Peker
@roipeker
Jan 11 2018 15:17
meaning for him or me?
i should port it ?
cause, 3 days ago my only knowledge came from AS3/Starling :D
i'm still trying to figure how to get IntelliSense, or modularize something on JS/VisualCode :D
my point is... i'm less than a newbie in this, but with a decent background
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:18
well it might work if you install pixi.js as an npm module
but no guarantees, i really dont know how Idea resolves jsdoc
Roi Peker
@roipeker
Jan 11 2018 15:19
i tried, and didnt.
VisualCode
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:19
vscode? ok, no idea
Roi Peker
@roipeker
Jan 11 2018 15:19
i used to do it on Idea/Webstorm
:D what do u use ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:19
Idea Ultimate
Roi Peker
@roipeker
Jan 11 2018 15:19
cool... same here for AS development.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:19
i write code on several languages, including AS
Roi Peker
@roipeker
Jan 11 2018 15:20
you usually code on TS ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:20
yep
Roi Peker
@roipeker
Jan 11 2018 15:20
Any tutorial that u wrote to setup everything there ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:20
well, i always have extra window opened with pixi github sources
also i dont use ES6 import/export, I use concatination built in ts compiler
Roi Peker
@roipeker
Jan 11 2018 15:21
mmm, ok...
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:21
and ///<reference paths="pixi.js"> to get typings for pixi
same for pixi plugins, most of my pixi plugins are written on TS
Roi Peker
@roipeker
Jan 11 2018 15:22
u mean for intellisense? code completion ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:22
yeah, code completion works fine for pixi ts :)
jsdoc arent
Roi Peker
@roipeker
Jan 11 2018 15:22
Do u recommend any tutorial for all that setup?
ouch!
and yet, in intellij u can define the library docs.
weird that is not compatible...
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:23
but as i said, its better to have pixi opened in separate window and ctrl+N classes when you need to look at them
typings can lie
Roi Peker
@roipeker
Jan 11 2018 15:23
by 'pixi opened' u mean the api docs ? http://pixijs.download/dev/docs/index.html
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:24
no, source code
Roi Peker
@roipeker
Jan 11 2018 15:24
ok
already did
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:24
docs are part of the code
Roi Peker
@roipeker
Jan 11 2018 15:24
therefore, "open pixi" source code where? another intellij idea project ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:24
yep
and if you have big screen, 27'' with 2560 width or so
just win+left pixi and win+right your project :)
Roi Peker
@roipeker
Jan 11 2018 15:25
OSX here.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:25
i dont know shortcuts there, just divide the screen into two )
Roi Peker
@roipeker
Jan 11 2018 15:25
gotcha.
@R_Talon_twitter
Jan 11 2018 15:26
github is down? :(
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:26
the great thing about pixi is that its not black box
almost everything is readable and understandable
Roi Peker
@roipeker
Jan 11 2018 15:26
understand.
but yet, the entire setup / migration process seems like a black box to me.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:26
except some difficult parts like Text or internals of SpriteRenderer
Roi Peker
@roipeker
Jan 11 2018 15:26
shaders are a diff deal, got it
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:26
i dont have tutorials for setup
Roi Peker
@roipeker
Jan 11 2018 15:27
ouch
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:27
but its really easy, just make tsconfig file like that:
Ivan Vodopiviz
@ivodopiviz
Jan 11 2018 15:27
migrating from AS to web tech is still pretty rough
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:27
{
    "compilerOptions": {
        "module": "none",
        "target": "es5",
    "noImplicitAny": true,
    "removeComments": true,
    "preserveConstEnums": true,
        "outFile": "bin/pixi-layers.js",
        "sourceMap": true,
        "inlineSources": true,
        "declaration": true,
        "typeRoots": [
          "lib/"
        ]
    },
    "include": [
        "src/**/*"
    ],
    "exclude": [
        "node_modules/**/*"
    ]
}
`
Roi Peker
@roipeker
Jan 11 2018 15:27
for me... definitely... maybe too late :D
Ivan Vodopiviz
@ivodopiviz
Jan 11 2018 15:28
there are a million tools that do mostly the same... and there's a new one in vogue every two weeks
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:28
outFile is where your js file goes
Roi Peker
@roipeker
Jan 11 2018 15:28
gotcha.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:28
either install everything through npm (like typings)
either put every definition in "lib/LIB_NAME/index.d.ts"
for pixi its "lib/pixi.js/index.d.ts"
you can just take a file from pixi-typescript and put it there, modify if you see something is wrong in typings
Roi Peker
@roipeker
Jan 11 2018 15:29
the definitions are available in the repo ? or this https://github.com/pixijs/pixi-typescript
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:29
yep
dont forget to ///<reference types="pixi.js"> and all its plugins somewhere
Roi Peker
@roipeker
Jan 11 2018 15:29
moving forware with the setup, how's gulp fit in this ? or u use webpack as well?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:30
just in one of your files in "src"
it doesnt
i just use plain tsc
i dont need gulp nor grunt for basic projects
but when i do, i use grunt
Roi Peker
@roipeker
Jan 11 2018 15:30
ok
and the debugging part ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:30
because it has grunt-ts , automatic reference thingy
"sourceMap": true,
"inlineSources": true,
see that part in tsconfig?
js.map file will be generated with sources
that's all
Roi Peker
@roipeker
Jan 11 2018 15:31
yep... but the run configuration itself, u define it in Intellij ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:31
I really dont like to use webpack and rollup and everything else for simple things
no, i run everything externally
even git, i use tortoiseGit and not intellij plugins
except when I use grunt - i run build from intellij, yeah, it has grunt task list
Roi Peker
@roipeker
Jan 11 2018 15:32
oh
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:33
so thats how i deal with IDE problems - i just use very simple configuration that works everywhere
Roi Peker
@roipeker
Jan 11 2018 15:33
So its like a node live http server that u run in a npm init ?.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:34
npm install -g http-server
http-server -c-1 -p8081 i run it in the directory i need
i prefer to have separate console windows for servers
Roi Peker
@roipeker
Jan 11 2018 15:34
ok
Wow, is so weird that github is down...
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:36
I love IDEs and I hope that I fix those problems in intellij idea for pixi-v5, its very very very bad at searching through lerna setup
as for TS, i even have TS fork for pixi, experimental. nobody uses it except me
that's how i know all pixi source code - i rewrote it multiple times , i made forks
Roi Peker
@roipeker
Jan 11 2018 15:37
nice
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:37
pixi is meant to be used as a renderer for custom engines
people like to make their own engines
Roi Peker
@roipeker
Jan 11 2018 15:38
I read so in the html5dev forums....
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:38
that's why the package is small
Roi Peker
@roipeker
Jan 11 2018 15:38
makes sense, same applies to Starling.
btw, as Starling integrated Multichannel DF ... pixi has it as well?
Gamua/Starling-Framework#994
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:39
there's pixi-sdf lib
you can modify it to get multichannel stuff
its plugin-level
Roi Peker
@roipeker
Jan 11 2018 15:40
ah, everything is modularized... gosh, i wish i can get an idea of how everything works.
How many AS3 devs around here?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:41
everything works with the help of someone's mother
Roi Peker
@roipeker
Jan 11 2018 15:41
Can i call u "mom" then? :D
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:42
no, i dont know which abominations mother is it.
probably one of chaos lords
Roi Peker
@roipeker
Jan 11 2018 15:42
b positive.
... i will start digging into this, and bother u.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:43
yes, almost everything is modularized
and v5 will be much better at it than v4
Roi Peker
@roipeker
Jan 11 2018 15:43
what's the current state of v5?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:44
for example, it allows to override texture uploading process, if you have custom alternative-gifted parameters for texImage2d or texStorage2d or texImage3d or i dont know what else
This message was deleted
https://github.com/pixijs/pixi.js/pulls ,look at [next], and closed [next]
Roi Peker
@roipeker
Jan 11 2018 15:46
1.7k closed? and 14 open...
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:46
1.7k for all pixi, since v1 ;)
Roi Peker
@roipeker
Jan 11 2018 15:46
:D sounded insane
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:47
Roi Peker
@roipeker
Jan 11 2018 15:48
that's a fucking rainbow of tickets :D
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:48
most of changes in v5 are dedicated to support of WebGL2 , and to new low-level API for geometry
Roi Peker
@roipeker
Jan 11 2018 15:48
yep, i noticed ...
so any estimates for RC1 ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:49
this month :)))
may be next week if we get more people working on it
Roi Peker
@roipeker
Jan 11 2018 15:49
that's optimistic ! ...
i should start with v5 u say?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:49
nooooo
Roi Peker
@roipeker
Jan 11 2018 15:49
:D
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:49
use v4 for now
Roi Peker
@roipeker
Jan 11 2018 15:49
that sounded fatalistic.
ok
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:49
its stable and its source is easier to view in intellij
and in vscode
it doesnt have lerna modules
Roi Peker
@roipeker
Jan 11 2018 15:50
understand.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:50
as for starling, im fan of another AS3 platform that was CANCELLED
starling runtimes are good, but i want complete flash api
Roi Peker
@roipeker
Jan 11 2018 15:51
Josh (Feathers) was working on a port no? NEXT something ?
oh complete flash API is ... kinda insane
u mean COMPLETE complete or display list stuffs?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:52
COMPLETE complete
Roi Peker
@roipeker
Jan 11 2018 15:52
if u have JS promises, u still wanna have an URLLoader?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:52
yep
Roi Peker
@roipeker
Jan 11 2018 15:52
that's be extremely amazing for me...
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:52
like, you take your old SWF, test in virtual machine, it works in JS environment with 2 Frames Per Second (ha-ha), then you convert AS3 to typescript automagically
and it works, and then you optimize it, use pixi in some places
that's what i want
Roi Peker
@roipeker
Jan 11 2018 15:53
how many old SWF u still have to port ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:53
but all UI's are vector on swf, no converted bullshit
Roi Peker
@roipeker
Jan 11 2018 15:53
i mean... old SWF are over 10 years ago ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:53
yep
not port, i wnat to make convertation mechanism
Roi Peker
@roipeker
Jan 11 2018 15:54
oh got it
but u could workaround the vector UI no ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:54
and a way for people to use vector in TS/JS
i need 1:1 vector and filter api's
Roi Peker
@roipeker
Jan 11 2018 15:54
like the current graphics ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:54
yeah, but current Graphics in pixi is very limited
Roi Peker
@roipeker
Jan 11 2018 15:55
at least u have something, Starling has an old extension
well, u have the readGraphicsData for the commands set
idk how u can super optimize that for webgl rendering.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:56
i believe its possible
but difficult
Roi Peker
@roipeker
Jan 11 2018 15:56
u want something like this:
http://blog.bwhiting.co.uk/?p=532
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:56
Flash was big
Roi Peker
@roipeker
Jan 11 2018 15:57
dont use past sentence... it makes me cry
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:57
yes, thank you for the link
ok, Flash is big, and there are apps of millions lines of code that work on it
Roi Peker
@roipeker
Jan 11 2018 15:57
yuep
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:57
its better to convert them rather then try rewrite
Roi Peker
@roipeker
Jan 11 2018 15:58
really?
and how could u optimize that?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:58
i dont need to optimize UI
if the game works, then game field can be rewritten to pixi
Roi Peker
@roipeker
Jan 11 2018 15:58
ok, u are talking about UI like making an app with Feathers? or game's UI ?
ah, ok
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:59
many games use Genome or other things like that, GL inside flash
Roi Peker
@roipeker
Jan 11 2018 15:59
oh boy, i miss genome.
Peter is always obsessed about performance.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:59
Peter?
Roi Peker
@roipeker
Jan 11 2018 15:59
I'm talking about Genome2D ... :P
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:59
ok
Roi Peker
@roipeker
Jan 11 2018 15:59
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 15:59
so if the app uses genome its not a problem to convert it to pixi
Roi Peker
@roipeker
Jan 11 2018 16:00
what the heck is genome ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:00
yeah, that genome2d
Roi Peker
@roipeker
Jan 11 2018 16:01
as far as i know... i just know 1 app i built on genome2d...
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:01
so imagine that you have a big app, huge UI's that just cant be converted to bitmap and has to be vector, and a huge field that uses genome2d already - it certainly can be fast in webgl, just switch from genome to pixi
Roi Peker
@roipeker
Jan 11 2018 16:01
how many games are made with that library?!
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:01
UI is the problem, no one has good vector stuff in JS
Roi Peker
@roipeker
Jan 11 2018 16:02
but, do u really need vectors ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:02
its not about Genome2d, its more about all custom things made with GL
Roi Peker
@roipeker
Jan 11 2018 16:02
i'm not aware of the internals of the rendering process.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:02
yeah, i need vectors and SWF because people still use flash editor
Genome is just good wrapper of GL in flash like pixi is for html5
Roi Peker
@roipeker
Jan 11 2018 16:03
GL like stencil masks ?
sorry my ignorance ...
i know that genome2d used some nape classes to parse the vector geometry...
but maybe i'm saying things totally unrelated :D
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:06
Genome2d uses Stage3D, right?
Roi Peker
@roipeker
Jan 11 2018 16:06
back in the days
i think he still supports it...
but since he moved to haxe, a few years ago...
webgl is supported as well
maybe u can dig into the source code and see if u find what ure looking for?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:07
so if a certain game uses Stage3D , and a wrapper like Genome - that part of the game can be moved to webgl just fine
its already performant enough
the problem is that UI cant be moved like that
Roi Peker
@roipeker
Jan 11 2018 16:07
ok.
but i insist, i have no clue how many devs adopted genome2d to build something... it wasnt popular at all.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:08
I think many people use Stage3D. As for Genome2d, I'm just lucky enough to be sitting on a project with millions of line of code that uses it
Roi Peker
@roipeker
Jan 11 2018 16:09
amazing!
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:09
so I used it as an analogy :) I believe other companies use something else but Stage3D anyway
Roi Peker
@roipeker
Jan 11 2018 16:09
probably
So u want vector rendering for JS / WebGL in v5
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:10
SUMMARY: main problem is vector, not performance. For performance we can do something, like move stuff to different API, but the app MUST WORK in new environment, even if its only 2FPS :)
its not related to v5
its related to Flash and Starling )
Roi Peker
@roipeker
Jan 11 2018 16:11
somehow...
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:11
i just told you my ideas how flash can be given an afterlife
Roi Peker
@roipeker
Jan 11 2018 16:11
yep
u want vectors back
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:12
yep
Roi Peker
@roipeker
Jan 11 2018 16:12
even if its CPU intensive.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:12
i believe performance issues can be solved independently.
Roi Peker
@roipeker
Jan 11 2018 16:12
But the vectors WILL BECOME textures on the rendering process ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:12
like, moving hot places to bitmap and pixi-v5 as a renderer ;)
Roi Peker
@roipeker
Jan 11 2018 16:13
like drawing a bitmap?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:13
yep :)
Roi Peker
@roipeker
Jan 11 2018 16:13
gotcha...
SWF > SVG > Texture ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:13
without SVG
seriously, dont mention it
Roi Peker
@roipeker
Jan 11 2018 16:13
why? seems reasonable
hahah why?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:13
its nightmare
Roi Peker
@roipeker
Jan 11 2018 16:13
dude, i never ever worked with it
really?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:14
its better to just skip that tech
Roi Peker
@roipeker
Jan 11 2018 16:14
wow, that's so anti HTML5.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:14
its for buttons and icons
Roi Peker
@roipeker
Jan 11 2018 16:14
SVG/CSS3 transforms is like "the performance" for web
and u want more complex stuffs? animations
but that was the point of the AIRBNB/after effects library no .?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:15
i mean, its not usable as a middle format
too different from SWF
and if you try to work with it, you'll see that its different across the browsers
Roi Peker
@roipeker
Jan 11 2018 16:16
:D then there's no "pos-life" for the FlashPlayer... u WANT the flash player.
AVM2 FTW :P
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:16
i want remove avm2 and use typescript
Roi Peker
@roipeker
Jan 11 2018 16:17
avm2 is a virtual machine, typescript is a transpiler.
bah, compiler
not related.
can't u reuse something made in haxe?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:17
that was a possibility
Roi Peker
@roipeker
Jan 11 2018 16:17
openfl needs to have something.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:18
we compared some outputs of vector for openfl and shumway, and shumway won
Roi Peker
@roipeker
Jan 11 2018 16:18
how does openfl targets web with linked swf
?
but shumway is out of the picture ...
dead
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:18
but its open-source :)
Roi Peker
@roipeker
Jan 11 2018 16:18
u will take it ?
wow dude... too much stuffs.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:19
they made some stupid decisions but overall it looks good
Roi Peker
@roipeker
Jan 11 2018 16:19
if u are able to do something cool with it...
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:19
so, AS3->TS works fine, and we dont need VM
just javascript vm is enough
and flash API's can be copied from shumway, openfl and other places
Roi Peker
@roipeker
Jan 11 2018 16:19
i'm still lost on the vector rendering process in that logic...
yep
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:19
but they have to be exact
shumway renders vector
im trying to understand how
Roi Peker
@roipeker
Jan 11 2018 16:20
in webgl ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:20
even if its in canvas, i can emulate that in gl
mozilla/shumway#2442
nothing serious yet, but i moved it to latest version of TS (in a separate branch) and im trying to understand their renderer code
the problem is that their setup is too difficult
it uses iframes and messages between them
Roi Peker
@roipeker
Jan 11 2018 16:22
:(
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:22
also AVM2 and stage intersecting too much
Roi Peker
@roipeker
Jan 11 2018 16:22
btw, u have 10 :+1:
:D
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:23
but i was able to play very difficult SWF files on it
thank you!
Roi Peker
@roipeker
Jan 11 2018 16:23
nice
looks promising
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:24
I think Flash is good enough, and its a shame Apple and Adobe killed it
there are no complete alternatives
Roi Peker
@roipeker
Jan 11 2018 16:25
tell me about it!
i'm banging my head to understand which path take for my work!
14+ years to the trash.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:25
I know the guy who uses old version of Flash to make his toons
Roi Peker
@roipeker
Jan 11 2018 16:26
that was the original COOLEST implementation
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:26
Flash5 or something like that
Roi Peker
@roipeker
Jan 11 2018 16:26
toons and entire videos around vector drawings.
yep
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:26
and he cant move to new version
Roi Peker
@roipeker
Jan 11 2018 16:26
hahaha
wtf
that's more monolitic than me using AS3 now a days.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:27
he just uses 3dmax and flash and few other tools
for video editing
but almost all the work is made in flash-5
Roi Peker
@roipeker
Jan 11 2018 16:27
insane...
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:27
here it is: youtube.com/watch?v=qcljlDHSKO0&list=PL5AEqoCf_ZF71GKdiD3MSVJIWHQnxqgNy
just copy&paste, i dont want gitter to post whole video here
Roi Peker
@roipeker
Jan 11 2018 16:28
nice work
tons of photoshop though.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:29
anyway, I really like the work we are doing on pixi-v5, and I also have separate work on vector renderer, and of course it will be compatible with pixi and will be available as a plugin
Roi Peker
@roipeker
Jan 11 2018 16:29
haha funny video
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:30
there are many videos in that list
he'
he's making new 30 minutes episode for 2 years already
better quality
Roi Peker
@roipeker
Jan 11 2018 16:30
hahahhahahaa
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:30
he
he's monster
Roi Peker
@roipeker
Jan 11 2018 16:30
handmade work
davinci of motion graphcis
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:30
step-by-step animation
so i took his SWF file for first episode
and gave it to shumway
and it worked!
Roi Peker
@roipeker
Jan 11 2018 16:32
and worked?
cool!!!!
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:32
except two places where masks are used
Roi Peker
@roipeker
Jan 11 2018 16:32
but dude, is like Flash 3?
yeah, masks
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:32
Flash 5
Roi Peker
@roipeker
Jan 11 2018 16:32
the SWF specs changed drastically no?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:32
shumway supports all swf formats
that's what i like in it - there are so many small things already in the engine
Roi Peker
@roipeker
Jan 11 2018 16:33
but its gigantic dude
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:33
I asked David Flannagan, he said shumway was 90% ready but 10% that were too difficult
in twitter
so now i think whether i can make a pivot and improve their renderer, and implement APIs that are missing
i dont need good performance, i need 2FPS
Roi Peker
@roipeker
Jan 11 2018 16:35
because 2FPS is just a bitmap :D
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:35
if it works, then its possible to convert all the code from AS3 to TS and fix the performance
Roi Peker
@roipeker
Jan 11 2018 16:35
best of lucks dude
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:35
of course that Typescript is modified a bit
it has int and uint types
Roi Peker
@roipeker
Jan 11 2018 16:36
so ?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:36
so it uses extra transforms for tsc compiler
and it supports instanceof for interfaces and some other things that JS/TS cant do
Roi Peker
@roipeker
Jan 11 2018 16:37
instanceof isnt supported ????!!!!
what do u use? typeof()=="something"
?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:37
its supported for classes
Roi Peker
@roipeker
Jan 11 2018 16:37
ah ok
not natives types
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:37
JS doesn't know about interfaces
and TS doesnt have reflection, it has only decorators and they are slow
so we need extra transforms for typescript to make it work like actionscript
and that part already works :)
Roi Peker
@roipeker
Jan 11 2018 16:40
@Ivan, I really need dig into this stuffs.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:40
try to understand pixi for now :)
Roi Peker
@roipeker
Jan 11 2018 16:40
haha
what about Typescript first?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:41
yeah, and TS
Roi Peker
@roipeker
Jan 11 2018 16:41
or ES6 for that matter!?
dude
haha, i'm fucked
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:41
TS is better
forget about import/export, just use plain concatenation for some time
Roi Peker
@roipeker
Jan 11 2018 16:41
"plain concatenation" is ....
:D
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:41
and gulp/grunt, you dont need them, simple npm package.json is fine for simple projects
tsc concatenates all files into one big TS file and then compiles it to JS
Roi Peker
@roipeker
Jan 11 2018 16:42
look
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:42
i gave you the config
Roi Peker
@roipeker
Jan 11 2018 16:42
check one of my videos...
that's sample project
that's pure spine runtime for html5
Roi Peker
@roipeker
Jan 11 2018 16:42
take something simple like this app, and tell me if its doable in Pixi:
vimeo.com/244156660
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:43
its doable on react or angular
Roi Peker
@roipeker
Jan 11 2018 16:43
ok
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:43
pixi is for sprites
Roi Peker
@roipeker
Jan 11 2018 16:43
yep
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:44
and ui.. really the only good ui is https://github.com/pixijs/pixi-ui , but it has no docs
its just lib that is used for tankwars.io project
people mostly use react/angular with pixi
html over canvas
Roi Peker
@roipeker
Jan 11 2018 16:45
:(
see? i'm super fucked.
isnt about learning Pixi dude ...
is Pixi, TS, gulp, react/angular, CSS ...
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:45
good luck :)
Roi Peker
@roipeker
Jan 11 2018 16:46
not enough sadly.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:46
take a mentor if you need constant help
but i dont think you need it, you're smart enough
just remember that if you see some technology as stupid, it actually might be stupid
some shit is overrated
Roi Peker
@roipeker
Jan 11 2018 16:50
like.. .the entire web?
diversification SUCKS
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:53
it made tech more open
but yeah, quality is under question
and people re-invent so many things, and some of those things are made more stupid than they were before
Roi Peker
@roipeker
Jan 11 2018 16:54
I hope that doesn't apply to game engines around pixi
:(
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:55
no, we actually have some innovations
Spine and Display plugins, texture rotations, e.t.c.
Roi Peker
@roipeker
Jan 11 2018 16:57
i saw the texture rotation thing.
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:58
it was born because Spine and TexturePacker pack textures into atlas differently. We need a way to rotate that shit
Roi Peker
@roipeker
Jan 11 2018 16:58
dunno about Spine...
but i didnt know it went beyond 90 degrees rotation for optimized spritesheets.
texture rotation to 45 degrees is weird
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 16:59
45 degrees is side-effect, it makes math easier in some cases
Roi Peker
@roipeker
Jan 11 2018 16:59
gotcha
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 17:00
the main idea is that you can change UVs instead of scale/rotate transform
Roi Peker
@roipeker
Jan 11 2018 17:00
should be way faster, no?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 17:01
its a bit faster and some cases are solved with it easier
Roi Peker
@roipeker
Jan 11 2018 17:04
@Ivan... https://github.com/kittykatattack/learningPixi is that a good intro?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 17:04
yep
Roi Peker
@roipeker
Jan 11 2018 17:04
i mean, i should start with plain JS? then move to TS?
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 17:05
you can do same things in TS from beginning if you are brave
Roi Peker
@roipeker
Jan 11 2018 17:05
I'm far from brave now... i feel like a scary dog in the rain
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 17:05
then start with plain js
es6 but no babel
use classes and stuff
hope that browsers support it
Roi Peker
@roipeker
Jan 11 2018 17:06
yeah............
is there any sample repo with TS/Idea files included?
is better to learn by example...
at least to analyze the boilerplate
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 17:22
take that spine repo
Roi Peker
@roipeker
Jan 11 2018 17:22
ok
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 17:22
its made by one of libgdx creators
it doesnt use pixi, it has custom renderer, but you may understand how simple TS projects work
Roi Peker
@roipeker
Jan 11 2018 17:23
cool
Ivan Popelyshev
@ivanpopelyshev
Jan 11 2018 17:23
that guy is old-school, he does not use anything fancy
Roi Peker
@roipeker
Jan 11 2018 17:24
alright, we'll c