aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/newview/llconsole.h
diff options
context:
space:
mode:
authorRobin Cornelius2010-10-10 22:10:33 +0100
committerRobin Cornelius2010-10-10 22:10:33 +0100
commitb3b30285126289f54b57bd42569bb0721e40e088 (patch)
treef4aaccb98d1a835c4ea376ec2803fc410a704052 /linden/indra/newview/llconsole.h
parentMerge branch 'mccabe-plugins' into plugins_merge (diff)
downloadmeta-impy-b3b30285126289f54b57bd42569bb0721e40e088.zip
meta-impy-b3b30285126289f54b57bd42569bb0721e40e088.tar.gz
meta-impy-b3b30285126289f54b57bd42569bb0721e40e088.tar.bz2
meta-impy-b3b30285126289f54b57bd42569bb0721e40e088.tar.xz
Revert "port of LL renderpipeline/Kirstens S19 pipeline for bridging to Viewer 2 texture system"
This reverts commit 087e15e89930d51c3964329befb273ae3b2d330d. Conflicts: linden/indra/newview/llsurface.cpp linden/indra/newview/llviewerwindow.cpp linden/indra/newview/llvoavatar.cpp linden/indra/newview/pipeline.cpp linden/indra/newview/pipeline.h
Diffstat (limited to '')
-rw-r--r--linden/indra/newview/llconsole.h47
1 files changed, 28 insertions, 19 deletions
diff --git a/linden/indra/newview/llconsole.h b/linden/indra/newview/llconsole.h
index 578670e..2915c48 100644
--- a/linden/indra/newview/llconsole.h
+++ b/linden/indra/newview/llconsole.h
@@ -33,8 +33,7 @@
33#ifndef LL_LLCONSOLE_H 33#ifndef LL_LLCONSOLE_H
34#define LL_LLCONSOLE_H 34#define LL_LLCONSOLE_H
35 35
36#include "llerrorcontrol.h" // For LLLineBuffer 36#include "llfixedbuffer.h"
37#include "llthread.h"
38#include "llview.h" 37#include "llview.h"
39#include "v4color.h" 38#include "v4color.h"
40#include <deque> 39#include <deque>
@@ -48,10 +47,10 @@ private:
48 F32 mLinePersistTime; // Age at which to stop drawing. 47 F32 mLinePersistTime; // Age at which to stop drawing.
49 F32 mFadeTime; // Age at which to start fading 48 F32 mFadeTime; // Age at which to start fading
50 LLFontGL* mFont; 49 LLFontGL* mFont;
50 S32 mLastBoxHeight;
51 S32 mLastBoxWidth;
51 S32 mConsoleWidth; 52 S32 mConsoleWidth;
52 S32 mConsoleHeight; 53 S32 mConsoleHeight;
53 LLMutex mQueueMutex;
54 LLTimer mTimer;
55 54
56public: 55public:
57 //A paragraph color segment defines the color of text in a line 56 //A paragraph color segment defines the color of text in a line
@@ -81,7 +80,14 @@ public:
81 80
82 typedef std::list<LineColorSegment> line_color_segments_t; 81 typedef std::list<LineColorSegment> line_color_segments_t;
83 82
84 typedef std::list<line_color_segments_t> lines_t; 83 //A line is composed of one or more color segments.
84 class Line
85 {
86 public:
87 line_color_segments_t mLineColorSegments;
88 };
89
90 typedef std::list<Line> lines_t;
85 typedef std::list<ParagraphColorSegment> paragraph_color_segments_t; 91 typedef std::list<ParagraphColorSegment> paragraph_color_segments_t;
86 92
87 //A paragraph is a processed element containing the entire text of the 93 //A paragraph is a processed element containing the entire text of the
@@ -92,7 +98,7 @@ public:
92 class Paragraph 98 class Paragraph
93 { 99 {
94 public: 100 public:
95 Paragraph (LLWString str, const LLColor4 &color, F32 add_time); 101 Paragraph (LLWString str, const LLColor4 &color, F32 add_time, LLFontGL* font, F32 screen_width);
96 void makeParagraphColorSegments ( const LLColor4 &color); 102 void makeParagraphColorSegments ( const LLColor4 &color);
97 void updateLines ( F32 screen_width, LLFontGL* font, bool force_resize=false ); 103 void updateLines ( F32 screen_width, LLFontGL* font, bool force_resize=false );
98 public: 104 public:
@@ -105,32 +111,35 @@ public:
105 }; 111 };
106 112
107 //The console contains a deque of paragraphs which represent the individual messages. 113 //The console contains a deque of paragraphs which represent the individual messages.
108 typedef std::deque<Paragraph*> paragraph_t; 114 typedef std::deque<Paragraph> paragraph_t;
109 paragraph_t mParagraphs; 115 paragraph_t mParagraphs;
110 paragraph_t mNewParagraphs;
111 116
112 // Font size: 117 // Font size:
113 // -1 = monospace, 0 means small, font size = 1 means big 118 // -1 = monospace, 0 means small, font size = 1 means big
114 LLConsole(const std::string& name, const LLRect &rect, 119 LLConsole(const std::string& name, const U32 max_lines, const LLRect &rect,
115 S32 font_size_index, F32 persist_time ); 120 S32 font_size_index, F32 persist_time );
116 ~LLConsole(); 121 ~LLConsole(){};
117 122
118 // each line lasts this long after being added 123 // each line lasts this long after being added
119 void setLinePersistTime(F32 seconds); 124 void setLinePersistTime(F32 seconds);
120 125
121 void reshape(S32 width, S32 height, BOOL called_from_parent = TRUE); 126 void reshape(S32 width, S32 height, BOOL called_from_parent = TRUE);
122 127
123 // -1 = monospace, 0 means small, font size = 1 means big 128 // -1 = monospace, 0 means small, font size = 1 means big
124 void setFontSize(S32 size_index); 129 void setFontSize(S32 size_index);
125 130
126 // From LLLineBuffer 131 void addLine(const std::string& utf8line, F32 size, const LLColor4 &color);
127 /*virtual*/ void clear(); 132 void addLine(const LLWString& wline, F32 size, const LLColor4 &color);
128 /*virtual*/ void addLine(const std::string& utf8line);
129 void addConsoleLine(const std::string& utf8line, const LLColor4 &color);
130 void addConsoleLine(const LLWString& wline, const LLColor4 &color);
131 133
132 // Overrides 134 // Overrides
133 /*virtual*/ void draw(); 135 /*virtual*/ void draw();
136
137 //do not make these two "virtual"
138 void addLine(const std::string& utf8line);
139 void addLine(const LLWString& line);
140
141private:
142 void updateBuffer() ;
134}; 143};
135 144
136extern LLConsole* gConsole; 145extern LLConsole* gConsole;