Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add loadVideo LoaderParser #9314

Merged
merged 11 commits into from
Apr 27, 2023
Merged

Add loadVideo LoaderParser #9314

merged 11 commits into from
Apr 27, 2023

Conversation

SuperSodaSea
Copy link
Member

@SuperSodaSea SuperSodaSea commented Mar 30, 2023

Description of change

Add loadVideo LoaderParser to support loading MP4 (.mp4 / video/mp4), WebM (.webm / video/webm) and OGG (.ogv / video/ogg) videos via PIXI.Assets.load().

Closes #9263.

TODO

Pre-Merge Checklist

  • Tests and/or benchmarks are included
  • Documentation is changed or added
  • Lint process passed (npm run lint)
  • Tests passed (npm run test)

@codesandbox-ci
Copy link

codesandbox-ci bot commented Mar 30, 2023

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit ac0f2ec:

Sandbox Source
pixi.js-sandbox Configuration

@bigtimebuddy
Copy link
Member

I know this is a draft, but super useful PR. Were you planning to do any browser feature-detection if the formats were supported? For instance, Safari does't support ogv.

@SuperSodaSea
Copy link
Member Author

Maybe we can add some detectXxx just like detectAvif and detectWebp 🤔

@dev7355608
Copy link
Collaborator

Could we add the config option to load all video files with autoPlay: false?

@dev7355608 dev7355608 mentioned this pull request Apr 1, 2023
4 tasks
@GoodBoyDigital
Copy link
Member

Maybe we can add some detectXxx just like detectAvif and detectWebp 🤔

Yes, lets definitely do this 👍

@GoodBoyDigital GoodBoyDigital added the 💞 Migrate to v8 This PR needs to be migrated to v8 label Apr 4, 2023
@bigtimebuddy bigtimebuddy added this to the v7.3.0 milestone Apr 19, 2023
@bigtimebuddy
Copy link
Member

Where are we on this @SuperSodaSea?

@SuperSodaSea
Copy link
Member Author

Need #9376

@bigtimebuddy
Copy link
Member

@SuperSodaSea done

@SuperSodaSea
Copy link
Member Author

It seems that VideoResource#load() will not resolve if url is data URL, need some investigation...

@dev7355608
Copy link
Collaborator

It seems that VideoResource#load() will not resolve if url is data URL, need some investigation...

@SuperSodaSea #9389 should fix that.

@SuperSodaSea
Copy link
Member Author

Could we add the config option to load all video files with autoPlay: false?

@dev7355608 I added a config.defaultAutoPlay option.

@SuperSodaSea SuperSodaSea marked this pull request as ready for review April 26, 2023 00:33
Copy link
Collaborator

@dev7355608 dev7355608 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe loadVideos (plural) instead of loadVideo would be more consistent with loadTextures (plural).

@bigtimebuddy
Copy link
Member

I think loadVideo, like loadSVG is fine. loadTextures is more likely wrong.

@bigtimebuddy bigtimebuddy added the ✅ Ready To Merge Helpful when issues are in the queue waiting to get merged. This means the PR is completed and has t label Apr 27, 2023
@bigtimebuddy bigtimebuddy merged commit 815d1fe into dev Apr 27, 2023
2 checks passed
@bigtimebuddy bigtimebuddy deleted the feature/load-video branch April 27, 2023 18:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
💞 Migrate to v8 This PR needs to be migrated to v8 ✅ Ready To Merge Helpful when issues are in the queue waiting to get merged. This means the PR is completed and has t
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Feature Request: Loading .webm files via PIXI.Assets.load()
4 participants