diff options
Diffstat (limited to 'OpenSim/Region/Framework/Interfaces/IDynamicTextureManager.cs')
-rw-r--r-- | OpenSim/Region/Framework/Interfaces/IDynamicTextureManager.cs | 57 |
1 files changed, 54 insertions, 3 deletions
diff --git a/OpenSim/Region/Framework/Interfaces/IDynamicTextureManager.cs b/OpenSim/Region/Framework/Interfaces/IDynamicTextureManager.cs index 1a3bcbb..6df5cc2 100644 --- a/OpenSim/Region/Framework/Interfaces/IDynamicTextureManager.cs +++ b/OpenSim/Region/Framework/Interfaces/IDynamicTextureManager.cs | |||
@@ -25,6 +25,8 @@ | |||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | */ | 26 | */ |
27 | 27 | ||
28 | using System; | ||
29 | using System.Drawing; | ||
28 | using System.IO; | 30 | using System.IO; |
29 | using OpenMetaverse; | 31 | using OpenMetaverse; |
30 | 32 | ||
@@ -33,7 +35,14 @@ namespace OpenSim.Region.Framework.Interfaces | |||
33 | public interface IDynamicTextureManager | 35 | public interface IDynamicTextureManager |
34 | { | 36 | { |
35 | void RegisterRender(string handleType, IDynamicTextureRender render); | 37 | void RegisterRender(string handleType, IDynamicTextureRender render); |
36 | void ReturnData(UUID id, byte[] data, bool isReuseable); | 38 | |
39 | /// <summary> | ||
40 | /// Used by IDynamicTextureRender implementations to return renders | ||
41 | /// </summary> | ||
42 | /// <param name='id'></param> | ||
43 | /// <param name='data'></param> | ||
44 | /// <param name='isReuseable'></param> | ||
45 | void ReturnData(UUID id, IDynamicTexture texture); | ||
37 | 46 | ||
38 | UUID AddDynamicTextureURL(UUID simID, UUID primID, string contentType, string url, string extraParams, | 47 | UUID AddDynamicTextureURL(UUID simID, UUID primID, string contentType, string url, string extraParams, |
39 | int updateTimer); | 48 | int updateTimer); |
@@ -125,11 +134,53 @@ namespace OpenSim.Region.Framework.Interfaces | |||
125 | // /// <param name='extraParams'></param> | 134 | // /// <param name='extraParams'></param> |
126 | // bool AlwaysIdenticalConversion(string bodyData, string extraParams); | 135 | // bool AlwaysIdenticalConversion(string bodyData, string extraParams); |
127 | 136 | ||
128 | byte[] ConvertUrl(string url, string extraParams); | 137 | IDynamicTexture ConvertUrl(string url, string extraParams); |
129 | byte[] ConvertData(string bodyData, string extraParams); | 138 | IDynamicTexture ConvertData(string bodyData, string extraParams); |
139 | |||
130 | bool AsyncConvertUrl(UUID id, string url, string extraParams); | 140 | bool AsyncConvertUrl(UUID id, string url, string extraParams); |
131 | bool AsyncConvertData(UUID id, string bodyData, string extraParams); | 141 | bool AsyncConvertData(UUID id, string bodyData, string extraParams); |
142 | |||
132 | void GetDrawStringSize(string text, string fontName, int fontSize, | 143 | void GetDrawStringSize(string text, string fontName, int fontSize, |
133 | out double xSize, out double ySize); | 144 | out double xSize, out double ySize); |
134 | } | 145 | } |
146 | |||
147 | public interface IDynamicTexture | ||
148 | { | ||
149 | /// <summary> | ||
150 | /// Input commands used to generate this data. | ||
151 | /// </summary> | ||
152 | /// <remarks> | ||
153 | /// Null if input commands were not used. | ||
154 | /// </remarks> | ||
155 | string InputCommands { get; } | ||
156 | |||
157 | /// <summary> | ||
158 | /// Uri used to generate this data. | ||
159 | /// </summary> | ||
160 | /// <remarks> | ||
161 | /// Null if a uri was not used. | ||
162 | /// </remarks> | ||
163 | Uri InputUri { get; } | ||
164 | |||
165 | /// <summary> | ||
166 | /// Extra input params used to generate this data. | ||
167 | /// </summary> | ||
168 | string InputParams { get; } | ||
169 | |||
170 | /// <summary> | ||
171 | /// Texture data. | ||
172 | /// </summary> | ||
173 | byte[] Data { get; } | ||
174 | |||
175 | /// <summary> | ||
176 | /// Size of texture. | ||
177 | /// </summary> | ||
178 | Size Size { get; } | ||
179 | |||
180 | /// <summary> | ||
181 | /// Signal whether the texture is reuseable (i.e. whether the same input data will always generate the same | ||
182 | /// texture). | ||
183 | /// </summary> | ||
184 | bool IsReuseable { get; } | ||
185 | } | ||
135 | } | 186 | } |