Creating 3D animated map video - node.js

https://docs.mapbox.com/mapbox-gl-js/example/query-terrain-elevation/
I did the same animation in the link using react native. Now I want to export this to a video.
I want user to click a button then everything to be done at backend. For example, send post request to
/api/createMapVideo and request body contains the coordinates of MarkerViews, polyLines etc... and use theese data to create animated map video then store it on cloud and after doing all of that send the url of video in the cloud as response. Like relive app's 3d videos.
How can I achieve this functionality? I want to create animated map video on backend. Or are there better solutions?

I did come across this on Github perhaps it helps as it's about EXPORTING THE CANVAS TO VIDEO and you can read more about this in this blog entry from a developer at Mapbox

Related

How can I Record video from webcam on client with lossless frame pixels through browser?

I need to build a website which recording the person from the camera (he must allow the camera first), but I need the record frame by frame with lossless pixels.
I tried to figure this out with some options:
opencv.js - didn't figure it, it is using the browser video element, this is changing the pixels by compressions right?
ngx-webcame - I read it using capturing lossless images but not video
Now the other issue that I need to send the frames to the server?
should I save the frames on client process it on client computer and then send the result to the server?
Is there an option to send the video data frame to the server for future use?
Someone told me to build an agent that will do this actions and send the data on chunks but in that case I don't know really how to do it and I need clarification on that and some instruction on how to start build something like that.
If anyone have an example codes or anything that can direct me to the solution it will be very helpful.
I've created something similar befor using RecordRTC.
It takes advantageg of WebRTC. It works pretty straitforward. Record the video localy and upload it as a file.
https://github.com/muaz-khan/RecordRTC

How To Capture WebRTC Stream From Different Page In NodeJS

I'm new to Node.js and WebRTC concept. I'm trying to make a an audio stream in which one of the page is the music controller and the other page is just playing whatever stream the music controller page is playing.
I based the idea on this link:
https://webrtc.github.io/samples/src/content/capture/video-pc/
But instead of video I just want audio. I'm able to make it work when they are on the same page but there is a problem when capturing stream from different page/url. NodeJS cannot access DOM elements so I'm stuck. I tried accessing the controller page audio element using document.getElementById but its not working. Please help how to get over this.

Can I record and upload video on Youtube API?

Can I use the YoutubeAPI on a web-app to record and save/upload a video with out it being broadcast live?
Use the method Videos: insert to upload video using YouTube api. About saving/downloading, I think, it's against their Terms of Service.
You shall not download any Content unless you see a “download” or
similar link displayed by YouTube on the Service for that Content.
You can see this SO post for further reference on downloading content in YouTube.
Youtube does not support recording straight to their platform anymore.
https://support.google.com/youtube/answer/57409?hl=en

Change image dimension while sending a Generic template message using Facebook graph api

I am trying to build a Facebook chatbot that sometimes sends image as response to user queries. These images are from the response of API requests from my node server and don't sit at my server end.
I am using Graph api to send messages automatically from the chatbot whenever a postback is received.
I am able to get image response back, but the images are not responsive. I have attached a picture for reference.enter image description here
From the Facebook documentation, I don't see any parameter that dynamically changes the image size. As the images I receive are from an external api and not from my server, is there a way around to change the image size and display the image with new dimensions in my chatbot.
Thanks in advance!
There is no image size exactly, but you can set the aspect ratio of the image, which will crop it to that ratio in the template. payload.image_aspect_ratio and the options are horizontal (1.91:1) or square (1:1).
You could also fetch the image with a third party API like Cloudinary, which will do image transforms on the fly.

Uploading user images to s3 and generating thumbnails from node

I'm currently considering developing a Meteor node.js app, but am struggling with how best to handle uploading of user images. In particular, I want to create a photography website that will allow the photographer to upload images in an 'admin' section, and these images will then be displayed on the website. I need to create a thumbnail of these images, and save the respective URLs to the database. I'm struggling with how to best accomplish this in meteor.
Is my best bet to use something like s3 combined with an AWS process for generating thumbnails?
Or should I save and host the images directly in the Meteor/node session?
Or should I scrap Meteor and use something like Express.js for this project?
Why don't you just use something like Filepicker.io to handle uploading and hosting images and simply store the image unique url (given to you by filepicker in the callback)?
Thumbnails can also be dynamically generated by Filepicker (using simple url modifications).
Cloudinary is a nicer alternative to filepicker when it comes to images, but integration process will be messier.
I would store the images on the filesystem, not in a database. If you have a unique id, you can use that as part of the url, for example an id of the item the image belongs to. Might look like this:
./uploads/img-<id>-<size>.jpg
You can write to disk and resize if necessary with node-imagemagick and your cdn should just poll these images from time to time. Not exactly sure how that part would work in terms of including the url to the image in the html.

Resources