mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-05-05 10:59:47 -05:00
Update all video assets to use local resource video
This commit is contained in:
@@ -2,19 +2,12 @@ local earth = asset.require("scene/solarsystem/planets/earth/earth")
|
||||
|
||||
|
||||
|
||||
local data = asset.syncedResource({
|
||||
Name = "Example Globe Video",
|
||||
Type = "UrlSynchronization",
|
||||
Identifier = "example_globe_video",
|
||||
Url = "http://liu-se.cdn.openspaceproject.com/files/examples/video/test-video.mp4"
|
||||
})
|
||||
|
||||
|
||||
local Layer = {
|
||||
Identifier = "ExampleVideo",
|
||||
Name = "Globe Video Loop Example",
|
||||
Identifier = "GlobeVideoLoopExample",
|
||||
Enabled = true,
|
||||
Type = "VideoTileLayer",
|
||||
Video = data .. "/test-video.mp4",
|
||||
Name = "Example Video"
|
||||
Video = asset.localResource("examplevideo.mp4"),
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -1,33 +0,0 @@
|
||||
local earth = asset.require("scene/solarsystem/planets/earth/earth")
|
||||
|
||||
|
||||
|
||||
local Layer = {
|
||||
Identifier = "ExampleVideoLocal",
|
||||
Type = "VideoTileLayer",
|
||||
Enabled = true,
|
||||
Video = asset.localResource("examplevideo.mp4"),
|
||||
Name = "Example Video Local"
|
||||
}
|
||||
|
||||
|
||||
asset.onInitialize(function()
|
||||
openspace.globebrowsing.addLayer(earth.Earth.Identifier, "ColorLayers", Layer)
|
||||
end)
|
||||
|
||||
asset.onDeinitialize(function()
|
||||
openspace.globebrowsing.deleteLayer(earth.Earth.Identifier, "ColorLayers", Layer)
|
||||
end)
|
||||
|
||||
asset.export("layer", Layer)
|
||||
|
||||
|
||||
|
||||
asset.meta = {
|
||||
Name = "Video Player Test",
|
||||
Version = "1.0",
|
||||
Description = "An example asset that shows how to include a video on Earth",
|
||||
Author = "OpenSpace Team",
|
||||
URL = "https://openspaceproject.com",
|
||||
License = "MIT"
|
||||
}
|
||||
@@ -2,14 +2,6 @@ local transforms = asset.require("scene/solarsystem/planets/earth/transforms")
|
||||
|
||||
|
||||
|
||||
local data = asset.syncedResource({
|
||||
Name = "Example Globe Video",
|
||||
Type = "UrlSynchronization",
|
||||
Identifier = "example_globe_video",
|
||||
Url = "http://liu-se.cdn.openspaceproject.com/files/examples/video/test-video.mp4"
|
||||
})
|
||||
|
||||
|
||||
local Plane = {
|
||||
Identifier = "VideoPlaneExample",
|
||||
Parent = transforms.EarthCenter.Identifier,
|
||||
@@ -23,8 +15,7 @@ local Plane = {
|
||||
Type = "RenderableVideoPlane",
|
||||
MirrorBackside = true,
|
||||
Size = 3E7,
|
||||
Video = data .. "/test-video.mp4",
|
||||
PlaybackMode = "RealTimeLoop"
|
||||
Video = asset.localResource("examplevideo.mp4"),
|
||||
},
|
||||
GUI = {
|
||||
Name = "Video Plane Example",
|
||||
|
||||
@@ -1,16 +1,8 @@
|
||||
local data = asset.syncedResource({
|
||||
Name = "Example Globe Video",
|
||||
Type = "UrlSynchronization",
|
||||
Identifier = "example_globe_video",
|
||||
Url = "http://liu-se.cdn.openspaceproject.com/files/examples/video/chlorophyll_model_2048.mp4"
|
||||
})
|
||||
|
||||
|
||||
local ScreenSpace = {
|
||||
Identifier = "ScreenSpaceVideoExample",
|
||||
Type = "ScreenSpaceVideo",
|
||||
Name = "Screen Space Video Example",
|
||||
Video = data .. "/chlorophyll_model_2048.mp4"
|
||||
Video = asset.localResource("examplevideo.mp4")
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -1,22 +1,14 @@
|
||||
local data = asset.syncedResource({
|
||||
Name = "Example Globe Video",
|
||||
Type = "UrlSynchronization",
|
||||
Identifier = "example_globe_video",
|
||||
Url = "http://liu-se.cdn.openspaceproject.com/files/examples/video/test-video.mp4"
|
||||
})
|
||||
|
||||
|
||||
local Sphere = {
|
||||
Identifier = "ExampleVideoOnSphere",
|
||||
Renderable = {
|
||||
Type = "RenderableVideoSphere",
|
||||
Size = 100.0,
|
||||
Segments = 80,
|
||||
Video = data .. "test-video.mp4",
|
||||
Video = asset.localResource("examplevideo.mp4"),
|
||||
Orientation = "Both"
|
||||
},
|
||||
GUI = {
|
||||
Name = "Video Sphere",
|
||||
Name = "Video Sphere Example",
|
||||
Path = "/Other/Spheres"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,24 +2,16 @@ local earth = asset.require("scene/solarsystem/planets/earth/earth")
|
||||
|
||||
|
||||
|
||||
local data = asset.syncedResource({
|
||||
Name = "Example Globe Video",
|
||||
Type = "UrlSynchronization",
|
||||
Identifier = "example_globe_video",
|
||||
Url = "http://liu-se.cdn.openspaceproject.com/files/examples/video/test-video.mp4"
|
||||
})
|
||||
|
||||
|
||||
local Layer = {
|
||||
Identifier = "TestVideo",
|
||||
Name = "Stretched Video Example",
|
||||
Identifier = "StretchedVideoExample",
|
||||
Type = "VideoTileLayer",
|
||||
Video = data .. "test-video.mp4",
|
||||
Video = asset.localResource("examplevideo.mp4"),
|
||||
StartTime = "2023 01 29 20:00:00",
|
||||
EndTime = "2023 01 29 21:00:00",
|
||||
Name = "Test Video",
|
||||
PlaybackMode = "MapToSimulationTime",
|
||||
Enabled = asset.enabled,
|
||||
Description = [[Video stretched to time]]
|
||||
Description = [[Video mapped to the simulation time in OpenSpace]]
|
||||
}
|
||||
|
||||
|
||||
@@ -36,7 +28,7 @@ asset.export(Layer)
|
||||
|
||||
|
||||
asset.meta = {
|
||||
Name = "Video Stretched To Time",
|
||||
Name = "Stretched Video Example",
|
||||
Version = "1.0",
|
||||
Description = "This is a video mapped to the simulation time in OpenSpace.",
|
||||
Author = "OpenSpace Team",
|
||||
|
||||
Reference in New Issue
Block a user