Blender  V3.3
ContextFunctions.cpp
Go to the documentation of this file.
1 /* SPDX-License-Identifier: GPL-2.0-or-later */
2 
9 #include "ContextFunctions.h"
10 
11 #include "../view_map/SteerableViewMap.h"
12 
13 #include "../system/TimeStamp.h"
14 
16 
17 unsigned GetTimeStampCF()
18 {
20 }
21 
22 unsigned GetCanvasWidthCF()
23 {
24  return Canvas::getInstance()->width();
25 }
26 
28 {
29  return Canvas::getInstance()->height();
30 }
31 
33 {
34  return Canvas::getInstance()->border();
35 }
36 
37 void LoadMapCF(const char *iFileName, const char *iMapName, unsigned iNbLevels, float iSigma)
38 {
39  return Canvas::getInstance()->loadMap(iFileName, iMapName, iNbLevels, iSigma);
40 }
41 
42 float ReadMapPixelCF(const char *iMapName, int level, unsigned x, unsigned y)
43 {
44  Canvas *canvas = Canvas::getInstance();
45  return canvas->readMapPixel(iMapName, level, x, y);
46 }
47 
48 float ReadCompleteViewMapPixelCF(int level, unsigned x, unsigned y)
49 {
51  return svm->readCompleteViewMapPixel(level, x, y);
52 }
53 
54 float ReadDirectionalViewMapPixelCF(int iOrientation, int level, unsigned x, unsigned y)
55 {
57  return svm->readSteerableViewMapPixel(iOrientation, level, x, y);
58 }
59 
61 {
63 }
64 
65 } // namespace Freestyle::ContextFunctions
Functions related to context queries.
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum const void *lists _GL_VOID_RET _GL_VOID const GLdouble *equation _GL_VOID_RET _GL_VOID GLdouble GLdouble blue _GL_VOID_RET _GL_VOID GLfloat GLfloat blue _GL_VOID_RET _GL_VOID GLint GLint blue _GL_VOID_RET _GL_VOID GLshort GLshort blue _GL_VOID_RET _GL_VOID GLubyte GLubyte blue _GL_VOID_RET _GL_VOID GLuint GLuint blue _GL_VOID_RET _GL_VOID GLushort GLushort blue _GL_VOID_RET _GL_VOID GLbyte GLbyte GLbyte alpha _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble alpha _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat alpha _GL_VOID_RET _GL_VOID GLint GLint GLint alpha _GL_VOID_RET _GL_VOID GLshort GLshort GLshort alpha _GL_VOID_RET _GL_VOID GLubyte GLubyte GLubyte alpha _GL_VOID_RET _GL_VOID GLuint GLuint GLuint alpha _GL_VOID_RET _GL_VOID GLushort GLushort GLushort alpha _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLint y
SteerableViewMap * getSteerableViewMap()
Definition: Canvas.h:163
void loadMap(const char *iFileName, const char *iMapName, unsigned iNbLevels=4, float iSigma=1.0f)
Definition: Canvas.cpp:297
static Canvas * getInstance()
Definition: Canvas.h:55
virtual BBox< Vec2i > border() const =0
float readMapPixel(const char *iMapName, int level, int x, int y)
Definition: Canvas.cpp:447
virtual int height() const =0
virtual int width() const =0
const FEdge * selectedFEdge() const
Definition: Canvas.h:169
float readSteerableViewMapPixel(unsigned iOrientation, int iLevel, int x, int y)
float readCompleteViewMapPixel(int iLevel, int x, int y)
static TimeStamp * instance()
Definition: TimeStamp.h:18
unsigned getTimeStamp() const
Definition: TimeStamp.h:23
float ReadCompleteViewMapPixelCF(int level, unsigned x, unsigned y)
float ReadDirectionalViewMapPixelCF(int iOrientation, int level, unsigned x, unsigned y)
void LoadMapCF(const char *iFileName, const char *iMapName, unsigned iNbLevels, float iSigma)
float ReadMapPixelCF(const char *iMapName, int level, unsigned x, unsigned y)
static unsigned x[3]
Definition: RandGen.cpp:73