VTK
9.2.6
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
Rendering
FFMPEGOpenGL2
vtkOpenGLMovieSphere.h
Go to the documentation of this file.
1
/*=========================================================================
2
3
Program: Visualization Toolkit
4
Module: vtkOpenGLMovieSphere.h
5
6
Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7
All rights reserved.
8
See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9
10
This software is distributed WITHOUT ANY WARRANTY; without even
11
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12
PURPOSE. See the above copyright notice for more information.
13
14
=========================================================================*/
35
#ifndef vtkOpenGLMovieSphere_h
36
#define vtkOpenGLMovieSphere_h
37
38
#include "
vtkNew.h
"
// for ivars
39
#include "
vtkOpenGLSkybox.h
"
40
#include "vtkRenderingFFMPEGOpenGL2Module.h"
// For export macro
41
#include "
vtkSmartPointer.h
"
// for ivars
42
#include <atomic>
// for ivars
43
#include <mutex>
// for ivars
44
45
class
vtkFFMPEGVideoSource
;
46
struct
vtkFFMPEGVideoSourceVideoCallbackData
;
47
class
vtkMutexLock
;
48
class
vtkOpenGLActor
;
49
class
vtkOpenGLPolyDataMapper
;
50
class
vtkTextureObject
;
51
52
class
VTKRENDERINGFFMPEGOPENGL2_EXPORT
vtkOpenGLMovieSphere
:
public
vtkOpenGLSkybox
53
{
54
public
:
55
static
vtkOpenGLMovieSphere
*
New
();
56
vtkTypeMacro(
vtkOpenGLMovieSphere
,
vtkOpenGLSkybox
);
57
void
PrintSelf
(ostream& os,
vtkIndent
indent)
override
;
58
62
void
Render
(
vtkRenderer
* ren,
vtkMapper
* mapper)
override
;
63
64
void
SetVideoSource(
vtkFFMPEGVideoSource
* val);
65
vtkFFMPEGVideoSource
* GetVideoSource();
66
67
protected
:
68
vtkOpenGLMovieSphere
();
69
~
vtkOpenGLMovieSphere
()
override
;
70
71
void
UpdateUniforms
(
vtkObject
*,
unsigned
long
,
void
*);
72
73
vtkNew<vtkTextureObject>
Textures[6];
74
int
BuildIndex
;
75
int
DrawIndex
;
76
int
YTexture
;
77
int
UTexture
;
78
int
VTexture
;
79
80
void
VideoCallback(
vtkFFMPEGVideoSourceVideoCallbackData
const
& cbd);
81
82
std::mutex
TextureUpdateMutex
;
83
unsigned
char
* TextureData[6];
84
int
ReadIndex
;
// access only within mutex
85
int
WriteIndex
;
86
87
std::atomic<int>
NewData
;
88
std::atomic<int>
HaveData
;
89
90
int
Height
;
91
int
Width
;
92
int
UVHeight
;
93
int
UVWidth
;
94
vtkSmartPointer<vtkFFMPEGVideoSource>
VideoSource
;
95
96
private
:
97
vtkOpenGLMovieSphere
(
const
vtkOpenGLMovieSphere
&) =
delete
;
98
void
operator=(
const
vtkOpenGLMovieSphere
&) =
delete
;
99
};
100
101
#endif
vtkOpenGLPolyDataMapper
PolyDataMapper using OpenGL to render.
Definition:
vtkOpenGLPolyDataMapper.h:58
vtkObject
abstract base class for most VTK objects
Definition:
vtkObject.h:62
vtkOpenGLMovieSphere
OpenGL MovieSphere, an optimized VR sphere for movies.
Definition:
vtkOpenGLMovieSphere.h:52
vtkOpenGLMovieSphere::Width
int Width
Definition:
vtkOpenGLMovieSphere.h:91
vtkOpenGLMovieSphere::UVHeight
int UVHeight
Definition:
vtkOpenGLMovieSphere.h:92
vtkRenderer
abstract specification for renderers
Definition:
vtkRenderer.h:72
vtkSmartPointer< vtkFFMPEGVideoSource >
vtkOpenGLSkybox.h
vtkOpenGLMovieSphere::ReadIndex
int ReadIndex
Definition:
vtkOpenGLMovieSphere.h:84
vtkOpenGLSkybox::UpdateUniforms
void UpdateUniforms(vtkObject *, unsigned long, void *)
vtkOpenGLSkybox::Render
void Render(vtkRenderer *ren, vtkMapper *mapper) override
Actual Skybox render method.
vtkOpenGLMovieSphere::VideoSource
vtkSmartPointer< vtkFFMPEGVideoSource > VideoSource
Definition:
vtkOpenGLMovieSphere.h:94
vtkOpenGLMovieSphere::NewData
std::atomic< int > NewData
Definition:
vtkOpenGLMovieSphere.h:87
vtkOpenGLActor
OpenGL actor.
Definition:
vtkOpenGLActor.h:34
vtkIndent
a simple class to control print indentation
Definition:
vtkIndent.h:39
vtkOpenGLMovieSphere::UVWidth
int UVWidth
Definition:
vtkOpenGLMovieSphere.h:93
vtkFFMPEGVideoSource
Reader for ffmpeg supported formats.
Definition:
vtkFFMPEGVideoSource.h:70
vtkOpenGLSkybox
OpenGL Skybox.
Definition:
vtkOpenGLSkybox.h:36
vtkOpenGLMovieSphere::DrawIndex
int DrawIndex
Definition:
vtkOpenGLMovieSphere.h:75
vtkMapper
abstract class specifies interface to map data to graphics primitives
Definition:
vtkMapper.h:87
vtkNew.h
vtkSmartPointer.h
vtkTextureObject
abstracts an OpenGL texture object.
Definition:
vtkTextureObject.h:43
vtkOpenGLSkybox::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkOpenGLMovieSphere::VTexture
int VTexture
Definition:
vtkOpenGLMovieSphere.h:78
vtkNew< vtkTextureObject >
vtkOpenGLMovieSphere::Height
int Height
Definition:
vtkOpenGLMovieSphere.h:90
vtkOpenGLMovieSphere::BuildIndex
int BuildIndex
Definition:
vtkOpenGLMovieSphere.h:74
vtkOpenGLSkybox::New
static vtkOpenGLSkybox * New()
vtkOpenGLMovieSphere::WriteIndex
int WriteIndex
Definition:
vtkOpenGLMovieSphere.h:85
vtkOpenGLMovieSphere::YTexture
int YTexture
Definition:
vtkOpenGLMovieSphere.h:76
vtkMutexLock
mutual exclusion locking class
Definition:
vtkMutexLock.h:82
vtkOpenGLMovieSphere::HaveData
std::atomic< int > HaveData
Definition:
vtkOpenGLMovieSphere.h:88
vtkOpenGLMovieSphere::TextureUpdateMutex
std::mutex TextureUpdateMutex
Definition:
vtkOpenGLMovieSphere.h:82
vtkFFMPEGVideoSourceVideoCallbackData
Definition:
vtkFFMPEGVideoSource.h:61
vtkOpenGLMovieSphere::UTexture
int UTexture
Definition:
vtkOpenGLMovieSphere.h:77
Generated on Mon Oct 16 2023 11:19:52 for VTK by
1.8.10